Skip to main content
diff options
authorLeo Ufimtsev2017-10-04 23:02:02 +0000
committerAlexander Kurtakov2017-10-05 10:05:00 +0000
commit61b1bc783bfeed2794539b90633fbaf9ac64819e (patch)
tree6383ced899e08283dc87aca95184f415f31f62d2 /bundles/org.eclipse.swt/.settings
parent5d455e5e20def7b9fbc72b6121f7b4bdade6828a (diff)
Bug 514859 [Webkit2] Verify that no webkit1-only functions are called on
Webkit2. As part of the webkit2 port, we must ensure that no webkit1 functions are ever called by webkit2. To ensure this, I've added assertions around native function calls. During the patch, I discovered multiple webkit1 only functions that were reached by webkit2. (Will post into bug). This patch has no real functional impact, only asserts, comments and some refactoring. Note: assertions are not executed normally, only by jUnits and if '-ea' is specified in vm args. Technical notes: - I moved the "WEBKIT2" variable and the logic that loads the native libraries from to, so that the native function wrappers can access the WEBKIT2 variable. I ensured that classes are loaded in proper order. - I added a WEBKIT1 flag for clarity. The negation !WEBKIT2 slows down code reading, it's very annoying. I also carefully ensured that there is no functional difference. - I added asserts around every webkit(1|2) function call. (I did this with some help of programmatically checking if a function is webkit1 or only webkit2). - Found some Webkit1 only functions being called on Webkit2 (see bug for details. See "TODO - guard from being called on webkit2" inline comments in patch). - Sprinkled some more asserts into and added comments. - Guarded a few Webkit1 only functions from being reached by webkit2 and added some TODO's into that code. - Found that my SWT_LIB_VERSIONS logic was calling a webkit2 only function when webkit2 was called. Fixed that up. - I changed org.eclipse.jdt.ui.prefs a bit so that it it doesn't turn static imports into "*" for WEBKIT1 and WEBKIT2 flag. (WEBKIT1 and WEBKIT2 flag is imported statically in, for sake of brevity). Testing - Junits for Webkit1 & Webkit2 - Child eclipse with webkit1 & webkit2 Change-Id: Ic63503e68e73974a0ca2c7716faabe5039df5ccb Signed-off-by: Leo Ufimtsev <>
Diffstat (limited to 'bundles/org.eclipse.swt/.settings')
1 files changed, 1 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/.settings/org.eclipse.jdt.ui.prefs b/bundles/org.eclipse.swt/.settings/org.eclipse.jdt.ui.prefs
index 5a9440f9dd..dc92561f1e 100644
--- a/bundles/org.eclipse.swt/.settings/org.eclipse.jdt.ui.prefs
+++ b/bundles/org.eclipse.swt/.settings/org.eclipse.jdt.ui.prefs
@@ -3,7 +3,7 @@ editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true

Back to the top