Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 56843 Details for
Bug 146894
Update manager paints invalid figures
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
patch suitable for 3.2.2
Patch_146894_322 (text/plain), 3.62 KB, created by
Alex Boyko
on 2007-01-12 14:14:41 EST
(
hide
)
Description:
patch suitable for 3.2.2
Filename:
MIME Type:
Creator:
Alex Boyko
Created:
2007-01-12 14:14:41 EST
Size:
3.62 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.draw2d >Index: META-INF/MANIFEST.MF >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.draw2d/META-INF/MANIFEST.MF,v >retrieving revision 1.12 >diff -u -r1.12 MANIFEST.MF >--- META-INF/MANIFEST.MF 2 Nov 2006 22:14:52 -0000 1.12 >+++ META-INF/MANIFEST.MF 12 Jan 2007 19:05:47 -0000 >@@ -2,7 +2,7 @@ > Bundle-ManifestVersion: 2 > Bundle-Name: Draw2d > Bundle-SymbolicName: org.eclipse.draw2d >-Bundle-Version: 3.2.1.qualifier >+Bundle-Version: 3.2.2.qualifier > Bundle-Vendor: Eclipse.org > Bundle-Localization: plugin > Import-Package: com.ibm.icu.text >Index: src/org/eclipse/draw2d/DeferredUpdateManager.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.draw2d/src/org/eclipse/draw2d/DeferredUpdateManager.java,v >retrieving revision 1.22 >diff -u -r1.22 DeferredUpdateManager.java >--- src/org/eclipse/draw2d/DeferredUpdateManager.java 5 Apr 2006 14:21:13 -0000 1.22 >+++ src/org/eclipse/draw2d/DeferredUpdateManager.java 12 Jan 2007 19:05:47 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2005 IBM Corporation and others. >+ * Copyright (c) 2000, 2007 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -52,9 +52,10 @@ > private GraphicsSource graphicsSource; > private List invalidFigures = new ArrayList(); > private IFigure root; >-private boolean updateQueued = false; >+private boolean updateQueued; > > private boolean updating; >+private boolean validating; > private RunnableChain afterUpdate; > > private static class RunnableChain { >@@ -136,19 +137,30 @@ > } > > void paint(GC gc) { >- SWTGraphics graphics = new SWTGraphics(gc); >- if (!updating) { >- /** >- * If a paint occurs not as part of an update, we should notify that the region >- * is being painted. Otherwise, notification already occurs in repairDamage(). >+ if (!validating) { >+ SWTGraphics graphics = new SWTGraphics(gc); >+ if (!updating) { >+ /** >+ * If a paint occurs not as part of an update, we should notify that the region >+ * is being painted. Otherwise, notification already occurs in repairDamage(). >+ */ >+ Rectangle rect = graphics.getClip(new Rectangle()); >+ HashMap map = new HashMap(); >+ map.put(root, rect); >+ firePainting(rect, map); >+ } >+ performValidation(); >+ root.paint(graphics); >+ graphics.dispose(); >+ } else { >+ /* >+ * If figures are being validated then we can simply >+ * add a dirty region here and update will repaint this region with other >+ * dirty regions when it gets to painting. We can't paint if we're not sure >+ * that all figures are valid. > */ >- HashMap map = new HashMap(); >- Rectangle rect = graphics.getClip(new Rectangle()); >- map.put(root, rect); >- firePainting(rect, map); >+ addDirtyRegion(root, new Rectangle(gc.getClipping())); > } >- root.paint(graphics); >- graphics.dispose(); > } > > /** >@@ -181,10 +193,11 @@ > * @see UpdateManager#performValidation() > */ > public void performValidation() { >- if (invalidFigures.isEmpty()) >+ if (invalidFigures.isEmpty() || validating) > return; > try { > IFigure fig; >+ validating = true; > fireValidating(); > for (int i = 0; i < invalidFigures.size(); i++) { > fig = (IFigure) invalidFigures.get(i); >@@ -193,6 +206,7 @@ > } > } finally { > invalidFigures.clear(); >+ validating = false; > } > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
ahunter.eclipse
:
iplog+
Actions:
View
|
Diff
Attachments on
bug 146894
:
54360
|
54567
|
54963
|
55517
|
55530
|
55531
|
55559
|
55871
| 56843