Skip to content

Commit 579ab29

Browse files
authored
Merge branch 'eclipse-platform:master' into master
2 parents 70f1595 + a9ec6c9 commit 579ab29

File tree

577 files changed

+139642
-2217
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

577 files changed

+139642
-2217
lines changed

.mvn/extensions.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
<extension>
44
<groupId>org.eclipse.tycho</groupId>
55
<artifactId>tycho-build</artifactId>
6-
<version>4.0.10</version>
6+
<version>4.0.12</version>
77
</extension>
88
</extensions>
Loading

bundles/org.eclipse.e4.ui.workbench.renderers.swt/icons/full/elcl16/view_menu.svg

Lines changed: 71 additions & 71 deletions
Loading
Loading

bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/AbstractContributionItem.java

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,10 +149,17 @@ void setResourceUtils(IResourceUtilities<ImageDescriptor> utils) {
149149
}
150150

151151
protected Image getImage(String iconURI, LocalResourceManager resourceManager) {
152+
return createImage(iconURI, resourceManager, false);
153+
}
154+
155+
private Image createImage(String iconURI, LocalResourceManager resourceManager, boolean disabled) {
152156
Image image = null;
153157

154158
if (iconURI != null && iconURI.length() > 0) {
155159
ImageDescriptor iconDescriptor = resUtils.imageDescriptorFromURI(URI.createURI(iconURI));
160+
if (disabled) {
161+
iconDescriptor = ImageDescriptor.createWithFlags(iconDescriptor, SWT.IMAGE_DISABLE);
162+
}
156163
if (iconDescriptor != null) {
157164
try {
158165
image = resourceManager.create(iconDescriptor);
@@ -169,6 +176,10 @@ protected Image getImage(String iconURI, LocalResourceManager resourceManager) {
169176
return image;
170177
}
171178

179+
private Image getDisabledImage(String iconURI, LocalResourceManager resourceManager) {
180+
return createImage(iconURI, resourceManager, true);
181+
}
182+
172183
protected void updateIcons() {
173184
if (!(widget instanceof Item)) {
174185
return;
@@ -184,14 +195,23 @@ protected void updateIcons() {
184195
Image iconImage = getImage(iconURI, resourceManager);
185196
item.setImage(iconImage);
186197
item.setData(ICON_URI, iconURI);
187-
if (item instanceof ToolItem) {
198+
if (item instanceof ToolItem toolItem) {
188199
iconImage = getImage(disabledURI, resourceManager);
189-
((ToolItem) item).setDisabledImage(iconImage);
190-
item.setData(DISABLED_URI, disabledURI);
200+
toolItem.setDisabledImage(iconImage);
201+
toolItem.setData(DISABLED_URI, disabledURI);
191202
}
192203
disposeOldImages();
193204
localResourceManager = resourceManager;
194205
}
206+
// if there is no explicit disabled icon and the element becomes disabled,
207+
// create it
208+
boolean hasExplicitDisabledImage = "".equals(disabledURI); //$NON-NLS-1$
209+
if (!modelItem.isEnabled() && !hasExplicitDisabledImage && item instanceof ToolItem toolItem) {
210+
if (toolItem.getDisabledImage() == null) {
211+
Image iconImage = getDisabledImage(iconURI, localResourceManager);
212+
toolItem.setDisabledImage(iconImage);
213+
}
214+
}
195215
}
196216

197217
private String getDisabledIconURI(MItem toolItem) {

bundles/org.eclipse.e4.ui.workbench3/META-INF/MANIFEST.MF

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Manifest-Version: 1.0
22
Bundle-ManifestVersion: 2
33
Bundle-SymbolicName: org.eclipse.e4.ui.workbench3;singleton:=true
4-
Bundle-Version: 0.17.400.qualifier
4+
Bundle-Version: 0.17.500.qualifier
55
Bundle-Name: %pluginName
66
Bundle-Vendor: %providerName
77
Bundle-Localization: plugin

bundles/org.eclipse.e4.ui.workbench3/src/org/eclipse/ui/testing/dumps/TimeoutDumpTimer.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
import org.eclipse.swt.graphics.Image;
4343
import org.eclipse.swt.graphics.ImageData;
4444
import org.eclipse.swt.graphics.ImageLoader;
45+
import org.eclipse.swt.graphics.Rectangle;
4546
import org.eclipse.swt.widgets.Control;
4647
import org.eclipse.swt.widgets.Display;
4748
import org.eclipse.swt.widgets.Shell;
@@ -285,7 +286,8 @@ public void run() {
285286

286287
// Take a screenshot:
287288
GC gc = new GC(display);
288-
final Image image = new Image(display, display.getBounds());
289+
Rectangle bounds = display.getBounds();
290+
final Image image = new Image(display, bounds.width, bounds.height);
289291
gc.copyArea(image, 0, 0);
290292
gc.dispose();
291293

bundles/org.eclipse.jface.notifications/META-INF/MANIFEST.MF

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@ Bundle-Name: %pluginName
44
Bundle-Vendor: %providerName
55
Bundle-Localization: plugin
66
Bundle-SymbolicName: org.eclipse.jface.notifications
7-
Bundle-Version: 0.7.300.qualifier
7+
Bundle-Version: 0.7.400.qualifier
88
Bundle-RequiredExecutionEnvironment: JavaSE-17
99
Export-Package: org.eclipse.jface.notifications,
1010
org.eclipse.jface.notifications.internal;x-internal:=true
1111
Automatic-Module-Name: org.eclipse.jface.notifications
1212
Require-Bundle: org.eclipse.core.runtime;bundle-version="3.29.0",
1313
org.eclipse.jface;bundle-version="3.20.0"
14+
Require-Capability: eclipse.swt;filter:="(image.format=svg)"
Lines changed: 47 additions & 0 deletions
Loading
Lines changed: 45 additions & 0 deletions
Loading

bundles/org.eclipse.jface.notifications/src/org/eclipse/jface/notifications/internal/CommonImages.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ public class CommonImages {
4949

5050
private static final String T_EVIEW = "eview16"; //$NON-NLS-1$
5151

52-
public static final ImageDescriptor NOTIFICATION_CLOSE = create(T_EVIEW, "notification-close.png"); //$NON-NLS-1$
53-
public static final ImageDescriptor NOTIFICATION_CLOSE_HOVER = create(T_EVIEW, "notification-close-active.png"); //$NON-NLS-1$
52+
public static final ImageDescriptor NOTIFICATION_CLOSE = create(T_EVIEW, "notification-close.svg"); //$NON-NLS-1$
53+
public static final ImageDescriptor NOTIFICATION_CLOSE_HOVER = create(T_EVIEW, "notification-close-active.svg"); //$NON-NLS-1$
5454

5555
private static ImageDescriptor create(String prefix, String name) {
5656
try {

bundles/org.eclipse.jface.text/META-INF/MANIFEST.MF

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,4 @@ Require-Bundle:
4040
Import-Package: com.ibm.icu.text
4141
Bundle-RequiredExecutionEnvironment: JavaSE-17
4242
Automatic-Module-Name: org.eclipse.jface.text
43+
Require-Capability: eclipse.swt;filter:="(image.format=svg)"

0 commit comments

Comments
 (0)