Ignore:
Timestamp:
05/19/21 09:01:33 (3 years ago)
Author:
davidb
Message:

A set of changes that spans three things: beat detection, time stretching; and a debug class motivated by the need to look at a canvas redraw issue most notable when a waveform widget is playing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/expeditee/gui/PopupManager.java

    r1175 r1561  
    118118                synchronized(_popups) {
    119119                        for (Popup popup : _popups) {
    120                                 if (popup.getBounds().contains(p)) {
    121                                         return true;
     120                                if (popup.getBounds().contains(p) && popup.isShowing()) {
     121                                                return true;
    122122                                }
    123123                        }
     
    199199        public void paint()
    200200        {
    201                 //Bryce: popups temporarly disabled due to them not working and interfering in things.
    202 //              synchronized (_popups) {
    203 //                      for (Popup popup : _popups) {
    204 //                              popup.update();
    205 //                              popup.paint();
    206 //                      }
    207 //              }
     201                /*
     202                if (Browser.DEBUG) {
     203                        System.out.println("**** PopupManger::paint() -- num popups in arraylist: " + _popups.size());
     204                }
     205                */
     206               
     207                //Bryce: popups temporarily disabled due to them not working and interfering in things.
     208                //David: block of code now reintroduced: still some issue but working through them.
     209               
     210                synchronized (_popups) {
     211                        for (Popup popup : _popups) {
     212                                popup.update();
     213                                popup.paint();
     214                        }
     215                }
     216               
    208217        }
    209218       
     
    252261                        }
    253262                       
     263                        if (Browser.DEBUG) {
     264                                System.out.println("*** PopupManager::upate() updating animationCurrentTime: " + currentTime);
     265                        }
    254266                        _animationCurrentTime = currentTime;
    255267                       
     
    353365                                setInitialBounds(fullBounds.clone());
    354366                                _initialBounds.getTopLeft().setY(_initialBounds.getTopLeft().getY() + _initialBounds.getSize().height);
     367                                //System.out.println("**** PopupManager::getAnimateBounds() forcing height to be fullBoundsHeight: ");
    355368                                _initialBounds.getSize().height = 0;
     369                                //_initialBounds.getSize().height = fullBounds.getHeight(); // used to be 0
    356370                        }
    357371                       
     
    360374                                percentShown = 1 - percentShown;
    361375                        }
    362                        
     376                        if (Browser.DEBUG) {
     377                                System.out.println("Percentage = " + percentShown + " " + fullBounds);
     378                        }
    363379                        return AxisAlignedBoxBounds.lerp(_initialBounds, fullBounds, percentShown);
    364380                }
Note: See TracChangeset for help on using the changeset viewer.