Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWim Jongman2018-05-04 13:34:51 +0000
committerWim Jongman2018-05-04 13:38:32 +0000
commit1c4402becd569b15b6e089cccd376d4578bb8494 (patch)
tree05f0891a29f72e66ba6488e1702b27cf06c814d1
parente3876fcc3376e482754750970a5d6d1b7a303413 (diff)
downloadeclipse.platform.ua-I20180506-0800.tar.gz
eclipse.platform.ua-I20180506-0800.tar.xz
eclipse.platform.ua-I20180506-0800.zip
* Fixed messageformat bug Change-Id: Ief616f182e0abec6e26079ac146e47cbfc37b971 Signed-off-by: Wim Jongman <wim.jongman@remainsoftware.com>
-rw-r--r--org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/Messages.java1
-rw-r--r--org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/TipComposite.java10
-rw-r--r--org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/messages.properties1
3 files changed, 5 insertions, 7 deletions
diff --git a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/Messages.java b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/Messages.java
index 3f9e51bc0..3acad9a7a 100644
--- a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/Messages.java
+++ b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/Messages.java
@@ -11,7 +11,6 @@ public class Messages extends NLS {
public static String TipComposite_10;
public static String TipComposite_11;
public static String TipComposite_12;
- public static String TipComposite_16;
public static String TipComposite_2;
public static String TipComposite_3;
public static String TipComposite_4;
diff --git a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/TipComposite.java b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/TipComposite.java
index 5791b677d..087683f0e 100644
--- a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/TipComposite.java
+++ b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/TipComposite.java
@@ -59,7 +59,7 @@ import org.eclipse.tips.ui.internal.util.ResourceManager;
@SuppressWarnings("restriction")
public class TipComposite extends Composite implements ProviderSelectionListener {
- private static final String EMTPY = ""; //$NON-NLS-1$
+ private static final String EMPTY = ""; //$NON-NLS-1$
private static final int READ_TIMER = 2000;
private TipProvider fProvider;
private Browser fBrowser;
@@ -495,15 +495,15 @@ public class TipComposite extends Composite implements ProviderSelectionListener
private static String getScaling() {
if (Platform.isRunning() && Platform.getWS().startsWith("gtk")) { //$NON-NLS-1$
Integer zoom = Integer.valueOf(DPIUtil.getDeviceZoom());
- return MessageFormat.format("<style>body { zoom: {0}%;}</style> ", zoom); //$NON-NLS-1$
+ return MessageFormat.format("<style>body '{' zoom: {0}%;'}'</style> ", zoom); //$NON-NLS-1$
}
- return EMTPY;
+ return EMPTY;
}
private String encodeImage(IHtmlTip tip) throws IOException {
TipImage image = tip.getImage();
if (image == null) {
- return EMTPY;
+ return EMPTY;
}
return encodeImageFromBase64(image);
}
@@ -512,7 +512,7 @@ public class TipComposite extends Composite implements ProviderSelectionListener
int width = fBrowser.getClientArea().width;
int height = Math.min(fBrowser.getClientArea().height / 2, (2 * (width / 3)));
String attributes = gtkHack(image.getIMGAttributes(width, height).trim());
- String encoded = EMTPY + "<center> <img " // //$NON-NLS-1$
+ String encoded = EMPTY + "<center> <img " // //$NON-NLS-1$
+ attributes //
+ " src=\"" // //$NON-NLS-1$
+ image.getBase64Image() //
diff --git a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/messages.properties b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/messages.properties
index 6350de6ee..2362c29b8 100644
--- a/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/messages.properties
+++ b/org.eclipse.tips.ui/src/org/eclipse/tips/ui/internal/messages.properties
@@ -5,7 +5,6 @@ TipComposite_1=Show tips at startup
TipComposite_10=Running
TipComposite_11=Tip read timer
TipComposite_12=Unknown Tip implementation:
-TipComposite_16=);</script>
TipComposite_2=Unread only
TipComposite_3=More...
TipComposite_4=New Button

Back to the top