Default settings for transitions


#1

It could be a good idea to have an option to set a default setting for transitions.
For example fade in/out for images, 1000 ms - so you would not have to do this for every image.


#2

Hello,
if you want to add a default transition for images per example here is what i did :
Go to the modules folder and look for image.module.php
open the file and look for public function SetRegionInformation($layoutid, $regionid)
you will find :
// Any Options
$this->SetOption(‘uri’, $this->storedAs);

add the folowing :
$this->SetOption(‘transIn’, “fly”);
$this->SetOption(‘transInDuration’, “1500”);
$this->SetOption(‘transInDirection’, “N”);
to make the default transition fly north for 1.5 sec


#3

Hi,
for text in the timeline how can I do the same ?
thanks


#5

Hello,
Look for the file : text.module.php, go to the function AddMedia() and
before the end add the following to make the inTransition random otherwise
you set it manually:

$trs = rand (0,1);

switch ($trs) {
    case 0:
    $this->SetOption('transIn', "fly");
    break;
    case 1:
    $this->SetOption('transIn', "fadeIn");
    break;
}

    $this->SetOption('transInDuration', "1500");

$trs = rand (0,7);

switch ($trs) {
    case 0:
    $this->SetOption('transInDirection', "N");
    break;
    case 1:
    $this->SetOption('transInDirection', "NE");
    break;
    case 2:
    $this->SetOption('transInDirection', "E");
    break;
    case 3:
    $this->SetOption('transInDirection', "SE");
    break;
    case 4:
    $this->SetOption('transInDirection', "S");
    break;
    case 5:
    $this->SetOption('transInDirection', "SW");
    break;
    case 6:
    $this->SetOption('transInDirection', "W");
    break;
    case 7:
    $this->SetOption('transInDirection', "NW");
    break;
}

Best regards.

KAMOUNI Mohamed
Contact : ( +212 ) 6 60 93 99 81
Software & Network Engineer
GNU/Linux user # 497173
Ubuntu User # 29208


#6

Thank you very much !


#7

Hi Peter,
i have been looking in the default transitions, but this is not implemented (yet)?
When I am on a cloud hosting I cannot change these settings myself, am I correct?

Regards, Peter


#8

It’s not implemented and not in the roadmap as far as I know.

Also you’re correct, as that would require direct code changes, that’s not possible in our Cloud - keep in mind also that the code snippets here are from 1.7 series.