Panning/scrolling movieclip, needs to stop and start on rollover/rollout

Hello, I just started a new flash developer job, but I am relatively new to Actionscript itself (seems dumb, I know).
The deal is that we have a movieclip with a jpg in it that we need to scroll left to right based on the mouse's position. This seems fairly straightforward, but there will also be FLV's (flvPlayback) and other various buttons to click on during the panning.
What I need is a way for the MC to stop panning upon rolling over one of the pre-determined buttons.
I inherited the code below and get what it is doing, but I have no idea how to make it stop panning when I need it to, and then "onRollOut" make it start panning again.
bg_mc.onEnterFrame = function() {
   if (hitTest(_root._xmouse, _root._ymouse, true)) {
       mover();
   } else {
       delete panoramic_mc.onEnterFrame;
function mover() {
   panoramic_mc.onEnterFrame = function() {
       if (_xmouse<movieMiddle) {
           if (panoramic_mc._x > movieWidth) {
               //trace("Move panoramic 1 back");
               panoramic_mc._x = (panoramic2_mc._x - panoramicWidth);
           if (panoramic2_mc._x > movieWidth) {
               //trace("Move panoramic 2 back");
               panoramic2_mc._x = (panoramic_mc._x  -panoramicWidth);
           inc = Math.abs(_xmouse - movieMiddle)*speed;
           panoramic_mc._x += inc;
           if(panoramic_mc._x > panoramic2_mc._x){
               panoramic2_mc._x = panoramic_mc._x - panoramicWidth;
           }else{
               panoramic2_mc._x = panoramic_mc._x + panoramicWidth;
       } else {
           if (panoramic_mc._x < (0 - panoramicWidth)) {
               //trace("Move panoramic 1 ahead");
               panoramic_mc._x = (panoramic2_mc._x + panoramicWidth);
           if (panoramic2_mc._x<(0 - panoramicWidth)) {
               //trace("Move panoramic 1 ahead");
               panoramic2_mc._x = (panoramic_mc._x + panoramicWidth);
           inc = Math.abs(_xmouse - movieMiddle)*speed;
           panoramic_mc._x -= inc;
           if(panoramic_mc._x > panoramic2_mc._x){
               panoramic2_mc._x = panoramic_mc._x - panoramicWidth;
           }else{
               panoramic2_mc._x = panoramic_mc._x + panoramicWidth;

when you want the panning to be active call activate():
function activate(){
bg_mc.onEnterFrame = function() {
   if (hitTest(_root._xmouse, _root._ymouse, true)) {
       panoramicF()
//when you want it to be inactive call deactivate():
function deactivate(){
delete bg_mc.onEnterFrame;
  function panoramicF() {
       if (_xmouse<movieMiddle) {
           if (panoramic_mc._x > movieWidth) {
               //trace("Move panoramic 1 back");
               panoramic_mc._x = (panoramic2_mc._x - panoramicWidth);
           if (panoramic2_mc._x > movieWidth) {
               //trace("Move panoramic 2 back");
               panoramic2_mc._x = (panoramic_mc._x  -panoramicWidth);
           inc = Math.abs(_xmouse - movieMiddle)*speed;
           panoramic_mc._x += inc;
           if(panoramic_mc._x > panoramic2_mc._x){
               panoramic2_mc._x = panoramic_mc._x - panoramicWidth;
           }else{
               panoramic2_mc._x = panoramic_mc._x + panoramicWidth;
       } else {
           if (panoramic_mc._x < (0 - panoramicWidth)) {
               //trace("Move panoramic 1 ahead");
               panoramic_mc._x = (panoramic2_mc._x + panoramicWidth);
           if (panoramic2_mc._x<(0 - panoramicWidth)) {
               //trace("Move panoramic 1 ahead");
               panoramic2_mc._x = (panoramic_mc._x + panoramicWidth);
           inc = Math.abs(_xmouse - movieMiddle)*speed;
           panoramic_mc._x -= inc;
           if(panoramic_mc._x > panoramic2_mc._x){
               panoramic2_mc._x = panoramic_mc._x - panoramicWidth;
           }else{
               panoramic2_mc._x = panoramic_mc._x + panoramicWidth;

Similar Messages

  • Is it necessary to regularly stop and start application to free memory?

    Do we need to stop and start an application regularly to free memory and increase performance? We have had random dynamic calc errors that went away after a stop/start.
    A consultant recommended we script a stop/start to run once per day. We are on version 7.
    I am concerned if the script stops an application while a calc is in progress - database corruption might occur.
    Thanks,
    J

    One big thing you should realize is that if your memory settings are really too large it does not manifest right away. As you perform certain actions the memory is allocated. So if you are on 32-bit Essbase which you are on a V7 platform the combination of your index + page + memory to support outline + calc caches * # of concurrent calcs + dynamic calc cache + about 200 MB needs to all be under 2 GB; when/if you get to a point of too much memory allocation you start getting quite a few interesting errors. Shutting down/starting up is not a proper long term way to manage memory issues -- properly setting the caches and other configurations is proper to resolve long term for that.
    Regards,
    John A. Booth
    http://www.metavero.com

  • Stop and start at same point?

    I want to be able to stop and start at one point in a song.
    As it is, when I press "play" from, for example, bar 3, then I hit stop at bar 6. I want to start again at bar 3, NOT bar 6. But for some reason Logic continues - like "scrolling" in ProTools.
    I do not want to use my mouse to click back bar 3.
    How do I stop / start at the same measure ?

    glankrudolph wrote:
    Here is what I need:
    Say I'm starting at measure 20. I place the playhead at measure 20. I press play and it plays for a few measures. I press stop, maybe at measure 24. Now, when I press play again, I want it to start at measure 20, like in ProTools.
    hi glank .. you need to get into the use of Markers. This will easily solve your issue:
    1 - Look up the Key Command for Create Marker at Playhead ( ie without Rounding)
    2 - Look up KC for "Go to Next Marker" & "Go to Previous Marker".
    3 - Place Playhead at measure 20. Press KC for "Create Marker without Rounding"
    4 - Play for a few measures and stop whenever you want to.
    5 - Now press the KC for "Go to previous marker" - with one stroke you are back at measure 20
    6 - Press Play
    If this is not quick and easy enough for you, I will eat my hat
    best
    m s

  • How may I automatically stop and start Mail services at a set time please

    Hi folks. I was wondering if anyone could tell me how to automatically stop and start Mail services (or any other services) at a set time please in Leopard Server? Is there a script someone has created which might help?
    Cheers, David ( a realy newbie when it comes to administering OS X server)

    launchd works through a series of XML documents that define tasks to run, either at launch, on a time schedule, in response to network events, etc.
    So you'll need to create two .plists - one to start the mail server and one to stop it. They should be saved in /Library/LaunchDaemons. I'd suggest something like:
    /Library/LaunchDaemons/local.postfix.stop.plist:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple
    .com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
      <key>Label</key>
      <string>local.postfix.stop</string>
      <key>ProgramArguments</key>
      <array>
        <string>/usr/sbin/serveradmin</string>
        <string>stop</string>
        <string>mail</string>
      </array>
      <key>StartCalendarInterval</key>
      <dict>
        <key>Hour</key>
        <integer>1</integer>
        <key>Minute</key>
        <integer>00</integer>
      </dict>
    </dict>
    </plist>
    and /Library/LaunchDaemons/local.postfix.start.plist:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple
    .com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
      <key>Label</key>
      <string>local.postfix.start</string>
      <key>ProgramArguments</key>
      <array>
        <string>/usr/sbin/serveradmin</string>
        <string>start</string>
        <string>mail</string>
      </array>
      <key>StartCalendarInterval</key>
      <dict>
        <key>Hour</key>
        <integer>4</integer>
        <key>Minute</key>
        <integer>00</integer>
      </dict>
    </dict>
    </plist>
    You'll need to either use launchctl load /Library/LaunchDaemons/local.postfix.stop (or start) to load the tasks, or reboot your server.
    I'm curious, though, as to why you want to do this. Mail is typically one of the services that people want to run 24/7 so they don't miss out on any emails (even though SMTP can tolerate this). Why do you want to shut yours down?

  • APEX 4.2 aligning issue of Stop and Start Grid Layout item

    My APEX application application is in the process of moving from 4.0 to 4.2.  I am experiencing an issue with aligning (left margin justified) of Stop and Start Grid Layout items that have a border around them.  Earlier I had an issue with the border itself not showing up in the 4.2 application.  I was able to resolve that with a workaround by adding inline code in the CSS section of the page: #P23_OFFICE_START_TBL {width:682; border:1px solid #369; margin:5px;}. This created the border which I needed, but there are 2 Stop and Start Grid Layout items that are indented and not aligning with the border of the previous line.  I have tried a number of different things but none of them have worked.  This seems like a very simple issue to fix but I am having a tough time resolving it.
    I tried to put the item in question in a different grid, which corrected the indention but then I lost the border around the item.  It seems that the above CSS code does not work on the new grid.  I also tried to put attributes such as margin-left:5px; float: left; clear: left; float: left, in the CSS code but that did not work, too.
    Any suggestions?
    Thanks
    Ajay K

    I deleted and added back the Stop and Start Grid Layout items not aligning properly.  This worked.  Apparently, the 4.0 to 4.2 upgrade did not handle/convert these items properly.  Deleting and adding them back resolved the issue.

  • Burned DVD issues in DVD player not reading or music issues stop and start

    I'm a PC converted to a MAC (less than a month) and love it so far. I have been able to create and burn a DVD. The problem I'm having is one DVD player will not read the DVD (Hitachi). The other DVD player will play it, but the music stops and starts when it transitions (twirl) to another picture (Panasonic DVD/VHS combo). I'm using a DVD R Memorex. Neither one of the player are new. Would love to use this to make the Grandparent's a DVD of the grandchildren from birth to present as Christmas present. What do I need to use or do to be able to watch on any DVD player as well as the computers?
    Message was edited by: me01

    Hi me01
    Welcome to apple discussions. Try using 99 photos / less to avoid issues with audio fades / drops. Also do a search for Memorex on this forum and you'll see it's not the first choice of dvd's for most users. Instead try Verbatim, Maxell, or Taiyo Yuden and burn at 4x from a disc image for best results. Wish you luck and feel free to post back with results or any further questions.
    Disclaimer: Apple does not necessarily endorse any suggestions, solutions, or third-party software / products that may be mentioned in this topic. Apple encourages you to first seek a solution at Apple Support. The following links are provided as is, with no guarantee of the effectiveness or reliability of the information. Apple does not guarantee that these links will be maintained or functional at any given time. Use the information above at your own discretion.
    Message was edited by: SDMacuser

  • Video stops and starts

    Sometimes video streaming makes images stop and start every 2 minutes or so,  and although it doesn't always happen the problem it's getting worse. Is there any way of fixing it? Thanks

    Do a Speedtest, you need at least 4Mbps to stream nicely.
    https://itunes.apple.com/sg/app/speedtest.net-mobile-speed/id300704847?mt=8

  • Stop and start databases

    I need to shutdown all my databases (ifs_Data and OEMREP), because computer people are going to run periodically a process to backup them. But I cannot find how to stop and start my oracle databases by commands (I need to create a bat file). I am using Win2000, Oracle 9 and iFS 9.0.1
    Thanks for the suggestions,

    This can be a procedure to shutdown a database:
    SET ORACLE_SID=<database_sid>
    sqlplus /nolog
    conn / as sysdba
    shutdown <option>;
    exit
    <option> = Abort ( Not recommendable ), Immediate, transactional, normal.
    Joel Pérez

  • Stop and Start Services

    Hi All,
    We are stopping and starting the services for daily backup. Is it advisable to stop and start services.
    Because client wants to stop the services before taking the backup anf start the services after backup.
    In this scenario, what services do we need to stop for backup process.
    Regards,
    Kumar

    Hi Saichand,
    Thanks for the response.
    Do u have any idea on the below:
    Our scenario is the below:
    We have a daily back of BI folders and Loading data from ERP to 10g database.
    We logged in with remote desktop user A from ABC system to BI system and We created a batch file to start and stop all the BI the services and scheduled this batch file using windows schedule tasks. These batch files will stop the BI services and after 30 minutes another batch file will load data into the database, after 2 hours start services batch file will start the BI services.
    When we open the BI Dashboards in the morning, all the dashboards and reports are working fine. But when I login to BI system, OC4J windows is not visible and dashboards are not coming and when we check the logs, LOGs says OC4J is running.
    Please suggest us the solution.
    Regards,
    Kumar
    Regards,
    Kumar
    Edited by: user597882 on Aug 26, 2010 3:35 AM

  • Stop and Start BI Publisher 12c OEM

    How to stop and start BI Publisher which is installed in 12c OEM. OMS is running on OEL 64 bit.
    I need a help in doing this step by step commands. Wherever i read it says Stop BI Publisher using weblogic Administration console which I don't have an idea...
    Please help on this...

    Please post it in Oracle Database community for better audience and responses.

  • Script to Stop and Start Oracle Meter Data Management

    Hi,
    This is my first post in Oracle forums so if i open this in the wrong thread please forgive me.
    I tried to create a windows batch script to stop and start Oracle Meter Data Management but i can´t.
    @echo off
    D:\spl\MDMDEV\bin\splenviron.cmd -e MDMDEV
    D:\spl\MDMDEV\bin\spl.cmd stop
    D:\spl\MDMDEV\bin\splenviron.cmd -e MDMDEV
    D:\spl\MDMDEV\bin\spl.cmd stop
    The batch exits in the first command and i can´t understand why.
    Another thing is if i use spl.cmd stop command it doesn´t do nothing, is this normal?
    Thanks in advanced for all replies.
    Best Regards.
    Nuno

    I had to put a call command in mine. I think it is because you are trying to run a .cmd file within your bat file. You're actually changing shells. Thats why you need the call.
    call d:\spl\mdmdev\bin\splenviron.cmd -e mdmdev
    call d:\spl\mdmdev\bin\spl.cmd start
    I actually set mine up to use variables so all I had to change from script to script was the environment...
    <snip>
    SET SPLENV=MDMDEV
    SET INSTALLDRIVE=D:
    SET INSTALLDIR=SPL
    SET BINDIR=%INSTALLDRIVE%\%INSTALLDIR%\%SPLENV%\bin
    %INSTALLDRIVE%
    cd %BINDIR%
    REM Set envornment
    call %BINDIR%\splenviron.cmd -e %SPLENV%
    REM Wait a few seconds for environment to setup
    ping localhost -n 5 > nul
    REM Start SPL Web
    call %BINDIR%\spl.cmd start
    </snip>
    I was unable to find a way to get this to run as a service. Have you?
    I'm currently running these scripts in the startup/shutdown script section of the local machine policy (gpedit.msc).

  • How to stop and Start ASM in 11gR2

    Hi,
    Any one please let me know the complete process of how to stop and start the ASM instance in
    11.2.0.1 oracle.
    Thanks.
    Ali

    Hi;
    If you need to close ASM than you need to also close database
    You need to close db:
    srvctl stop database -d instance_name
    or
    set ORACLE_HOME and ORACLE_SID
    sqlplus "/as sysdba"
    shutdown immediate;
    srvctl stop LISTENER
    srvctl stop ASM -f
    or see:
    Stop asm instance in standalone database
    Re: Stop asm instance in standalone database
    Regard
    Helios

  • Cluster stop and start

    Hi Experts ,
    Is it possbile to stop and start the Sun cluster as like VCS (hastop and hastart).
    Regards,
    R.Rajesh Kannan.

    So many questions!
    It depends what you're trying to achieve. Sun Cluster is only started and stopped when you boot/shutdown Solaris.
    However, may be you actually only want to be able to make changes to a service without Sun Cluster trying to restart it, etc. If that is the case, then you simply need to disable the monitoring on the service in question and then you can do what you like with the service and Sun Cluster won't react.
    A typical example would be for HA-Oracle. If you don't stop the monitoring and then have the DBA try and shutdown the database, they will find that Sun Cluster detected the 'failure' and restarted the service. However, disabling the monitoring will allow the DBA to shutdown Oracle manually, make their changes and bring it back up again. The monitoring can then be re-enabled on the database.
    Tim
    ---

  • While playing videos on itunes, audio and video will stop and start. It just started doing this recently and it does it with all my itunes videos..help!!

    While playing videos on itunes, the audio and video will stop and start several times during playback. This just started recently and it does it on all my videos. Help!!

    Try to download the application VLC.
    It is a media player that should be able to play any audio or video file you may have. If your videos play flawlessly using that application, then the issue is with iTunes and Quicktime, as they are both essentially similar software types when it comes to playing media.
    In that case you may need to install a plug-in file called Perian, in order for the videos to play correctly within iTunes or at least Quicktime...

  • Tools and Script for stopping and starting SAP instances in the landscape

    Hi All,
    All our SAP system are on Windows 2003 and very few on Windows 2000.
    Is there any possiblity for having a script which will stop and start SAP on all the instances in the Landscape from a central system?
    Lets say we have some 200 SAP instances and we need to down all the instances for Windows patching.
    In this case, we need to manually take remote desktop to stop and start all the instances one by one.
    Also, do we have any 3rd party automated tools for this purpose?
    Regards,
    Siva.

    Hi Siva,
    You can configure ACC for your system landscape.
    http://help.sap.com/saphelp_nwmobile71/helpdata/en/83/43cd574af1489aadd4d71b2f47b77d/content.htm
    Thanks
    Atul

Maybe you are looking for

  • Problem using ebook text for LR4

    I have been using the ebook text Classroom in a Book for Lightroom 4.  I am working on two screens:  Classroom in a Book is on the secondary screen; LR4 is on the main screen.  I have gone through 4 of the lessons.  At some point during Lesson 4 I mu

  • JDeveloper 10.1.3.5.0 and jdk1.7.0_06

    Hi, I'm trying to use JDeveloper 10.1.3.5.0 with jdk1.7.0_06 and i'm getting the error "Unable to launch the Java Virtual Machine" at path... when trying to launch JDeveloper. I checked the path and jvm.dll is on the right path : path\jdk1.7.0_06\jre

  • Another code completion bug

    At some point during my editing the code completion system got screwed up. This has also caused the "Go to Definition" feature (holding CTRL key and hovering mouse over element where you want to see the definition for) to work incorrectly - see scree

  • Preventing printing

    Hi all I have a requirement for the app I am developing in Apex 3.0... some users should not be able to "print" anything from the application (based on their authorisation level). By "print" they mean saving as CSV, generating PDF and even printing v

  • EDPAR and idoc segment E1EDKA1

    Hi    I have read all threads related to EDPAR but didn't get any satisfactory answer.    I have maintained entries in EDPAR table thru t-code VOE4. I understand that I need to pass 'customer' and 'external partner' number in idoc to automatically de