This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

View | Details | Raw Unified | Return to bug 170625
Collapse All | Expand All

(-)a/progress.ui/src/org/netbeans/modules/progress/ui/ListComponent.java (+13 lines)
Lines 265-270 Link Here
265
            mainLabel.repaint();
265
            mainLabel.repaint();
266
        }
266
        }
267
    }
267
    }
268
269
    //Called to clear the progressbar
270
    void clearProgressBarOSX() {
271
        //EMI: On OSX, an animation thread is started when the progressbar is created, even if not displayed (or added to a container).
272
        // The following line is needed to kill the animation thread otherwise this tends to be alive for the rest of the JVM execution
273
        // pumping a lot of repaing events in the event queue (in my tests, about 50% of the CPU while idle).
274
        // The culprit apple.laf.CUIAquaProgressBar$Animator was discovered with the normal Profiler, while Tim Boudreau told me about a similar
275
        // problem with OSX and the pulsating button (that also has a thread for that animation).
276
        // Finally, btrace and this IDEA bug report (http://www.jetbrains.net/jira/browse/IDEADEV-25376) connected the dots.
277
        if(bar!=null){
278
            bar.getUI().uninstallUI(bar);
279
        }
280
    }
268
    
281
    
269
    private class MListener extends MouseAdapter {
282
    private class MListener extends MouseAdapter {
270
        public void mouseClicked(MouseEvent e) {
283
        public void mouseClicked(MouseEvent e) {
(-)a/progress.ui/src/org/netbeans/modules/progress/ui/StatusLineComponent.java (-1 / +11 lines)
Lines 182-187 Link Here
182
    private void discardBar() {
182
    private void discardBar() {
183
        if (bar != null) {
183
        if (bar != null) {
184
            bar.removeMouseListener(mouseListener);
184
            bar.removeMouseListener(mouseListener);
185
			//EMI: On OSX, an animation thread is started when the progressbar is created, even if not displayed (or added to a container).
186
			// The following line is needed to kill the animation thread otherwise this tends to be alive for the rest of the JVM execution
187
			// pumping a lot of repaing events in the event queue (in my tests, about 50% of the CPU while idle).
188
			// The culprit apple.laf.CUIAquaProgressBar$Animator was discovered with the normal Profiler, while Tim Boudreau told me about a similar
189
			// problem with OSX and the pulsating button (that also has a thread for that animation).
190
			// Finally, btrace and this IDEA bug report (http://www.jetbrains.net/jira/browse/IDEADEV-25376) connected the dots.
191
			bar.getUI().uninstallUI(bar);
185
            bar = null;
192
            bar = null;
186
        }
193
        }
187
    }
194
    }
Lines 440-451 Link Here
440
    }
447
    }
441
    
448
    
442
    private void removeListItem(InternalHandle handle) {
449
    private void removeListItem(InternalHandle handle) {
443
        handleComponentMap.remove(handle);
450
        ListComponent c = handleComponentMap.remove(handle);
444
        pane.removeListComponent(handle);
451
        pane.removeListComponent(handle);
445
        pane.updateBoldFont(model.getSelectedHandle());
452
        pane.updateBoldFont(model.getSelectedHandle());
446
        if (showingPopup) {
453
        if (showingPopup) {
447
            resizePopup();
454
            resizePopup();
448
        }
455
        }
456
        if (c != null) {
457
            c.clearProgressBarOSX();
458
        }
449
    }
459
    }
450
460
451
    
461
    

Return to bug 170625