CPP-7228 CMake console doesn't display broken configurations on Windows
authorVasily Pisar <vasily.pisar@jetbrains.com>
Wed, 10 Aug 2016 13:03:40 +0000 (16:03 +0300)
committerVasily Pisar <vasily.pisar@jetbrains.com>
Wed, 10 Aug 2016 13:12:41 +0000 (16:12 +0300)
- watermark icon (i.e. semi-transparent and pale) for non-selected tabs

platform/platform-impl/src/com/intellij/openapi/wm/impl/content/TabbedContentTabLabel.java

index b87dfff078f246e6d2a4f90584ce4a0a59ec170d..7e2d2cf8578faa9839133aae6d6232a404b8f94a 100644 (file)
@@ -28,6 +28,7 @@ import com.intellij.ui.content.TabbedContent;
 import com.intellij.util.NotNullFunction;
 import com.intellij.util.ui.EmptyIcon;
 import com.intellij.util.ui.UIUtil;
+import com.intellij.util.ui.WatermarkIcon;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
 
@@ -151,7 +152,8 @@ public class TabbedContentTabLabel extends ContentTabLabel {
       if (nextTabWithName.getFirst().equals(myContent.getTabNameWithoutPrefix(tabName))) {
         JComponent tab = nextTabWithName.getSecond();
         if (tab instanceof Iconable) {
-          jLabel.setIcon(((Iconable)tab).getIcon(Iconable.ICON_FLAG_VISIBILITY));
+          Icon baseIcon = ((Iconable)tab).getIcon(Iconable.ICON_FLAG_VISIBILITY);
+          jLabel.setIcon(isSelected() ? baseIcon : new WatermarkIcon(baseIcon, .5f));
         }
       }
     }