Skip to content

Commit

Permalink
Merge master into GradleFrontendProject
Browse files Browse the repository at this point in the history
  • Loading branch information
dukescript committed Apr 20, 2019
2 parents caa31fd + d3d19fa commit e03eba2
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 15 deletions.
1 change: 1 addition & 0 deletions groovy/gradle/manifest.mf
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ OpenIDE-Module: org.netbeans.modules.gradle
OpenIDE-Module-Layer: org/netbeans/modules/gradle/layer.xml
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/gradle/Bundle.properties
OpenIDE-Module-Specification-Version: 1.1
OpenIDE-Module-Requires: cnb.org.netbeans.modules.groovy.kit
31 changes: 16 additions & 15 deletions platform/api.htmlui/src/org/netbeans/modules/htmlui/NbBrowsers.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,29 +60,30 @@ public void run() {

static void applyNbSkin() {
LookAndFeel lookAndFeel = UIManager.getLookAndFeel();
String name = lookAndFeel.getName();
String name = findLafName(lookAndFeel.getName());
if (name == null) {
return;
}
String resource = "nbres:/org/netbeans/modules/htmlui/css/wizard-" + name + ".css";
loadCss(resource);
}

private static String findLafName(String name) {
switch (name) {
case "Mac OS X":
name = "mac";
break;
return "mac";
case "Metal":
name = "metal";
break;
return "metal";
case "GTK look and feel":
name = "gtk";
break;
return "gtk";
case "Nimbus":
name = "nimbus";
break;
return "nimbus";
case "Windows":
name = "win";
break;
return "win";
case "Darcula":
name = "darcula";
break;
return "darcula";
}
final String resource = "nbres:/org/netbeans/modules/htmlui/css/wizard-" + name + ".css";
loadCss(resource);
return null;
}

@JavaScriptBody(args = { "css" }, body =
Expand Down

0 comments on commit e03eba2

Please sign in to comment.