Extensible ComboBox Controller

Flexible ComboBox Controller that can execute any command, list of commands, or function from the xml, not just loading panoramas Demo of ExtensibleController - Download .swf

This is a "smart plugin". It is not loaded on a layer; it is loaded in a spot. For example:

<panorama>
<parameters>
        ...
</parameters>
<...>
</...>
<hotspots>
        <global myFunction = "pano.tilt = 45, 500, smooth; pano.pan = 180,500,smooth;">
                <spot id="myid" url="plugins/ExtensibleController.swf" static="1" salign=".5" staticX="0" staticY="0"
comboBoxActions = "
select...|
Load a pano | loadPano(?panoName=mypano,300,fade);
Up brightness | pano.brightness += .2;
Down brightness | pano.brightness -= .2;
Pan around | myFunction;
"

/>

....
        </global>
</hotspots>
</panorama>

Each line in the comboBox should be on it own line in the xml, and the pipe character, |, separates the label from the command, list of commands, or function defined elsewhere in the xml. The commands that ExtensibleController can execute are anything that the hotspots.execute() method can execute, in other words, if you can execute it with a normal button, you can execute it with ExtensibleController.

The user configurable parameters, their default values, and effects are listed below, and they should ALL be set within the <spot> tag.

  • comboBoxActions -> each line in the xml contains the label and action separated by a | character
  • comboBoxFont: Arial -> the font for the selected item in the combobox.
  • comboBoxColor: 0x000000 -> the font color for the selected item in the combobox.
  • comboBoxFontSize: 14 -> the font point size for the selected item in the combobox.
  • comboBoxWidth: 200 -> the pixel width of the combobox. If it is not set wide enough to accomodate the longest label, the label will be clipped.
  • comboBoxHeight: 30 -> the pixel height of the combobox. If it is not set tall enough to accomodate the font size, the label will be clipped.
  • Hi Zephyr, I have not been

    Hi Zephyr,

    I have not been able to get your myFunction execute. The brightness adjustments and pano load work well. The only plugins I load are the hotspot plugin and the movdecoder as i am showing qt panos. Otherwise, i used your exact xml sample . . .

    -andras

    Hello, Is it possible to

    Hello,
    Is it possible to change other colors that the font colors (background when combo is open, rollover color, etc ...) ?
    Regards,
    Dimitri

    Pan around |

    Pan around | global.myFunction;

    . . . does the trick.

    Thanks, Zephyr.

    Hi Zephyr! Could you

    Hi Zephyr!
    Could you implement a configurable parameter "comboBoxRowCount" to pass the param. rowCount to the flash component?? (or send me a FLA so will make it) Scrolling in the options-list is a pretty usability clog.

    greetz
    tom.t