亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? basicoutlookbarui.java

?? java swing控件
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
    TabButton button = (TabButton)tabToButton.get(removedTab);
    tabPane.remove(button);
    buttonToTab.remove(button);
    tabToButton.remove(removedTab);
  }

  /**
   * Called whenever a property of a tab is changed
   * 
   * @param index
   */
  protected void updateTabButtonAt(int index) {
    TabButton button = buttonForTab(index);
    button.setText(tabPane.getTitleAt(index));
    button.setIcon(tabPane.getIconAt(index));
    button.setDisabledIcon(tabPane.getDisabledIconAt(index));
    
    Color background = tabPane.getBackgroundAt(index);
    if (background == null) {
      background = (Color)button.getClientProperty(BUTTON_ORIGINAL_BACKGROUND);
    }
    button.setBackground(background);
    
    Color foreground = tabPane.getForegroundAt(index);
    if (foreground == null) {
      foreground = (Color)button.getClientProperty(BUTTON_ORIGINAL_FOREGROUND);
    }    
    button.setForeground(foreground);
    
    button.setToolTipText(tabPane.getToolTipTextAt(index));
    button
      .setDisplayedMnemonicIndex(tabPane.getDisplayedMnemonicIndexAt(index));
    button.setMnemonic(tabPane.getMnemonicAt(index));
    button.setEnabled(tabPane.isEnabledAt(index));
    button.setHorizontalAlignment(((JOutlookBar)tabPane).getAlignmentAt(index));
  }

  protected TabButton buttonForTab(int index) {
    Component component = tabPane.getComponentAt(index);
    return (TabButton)tabToButton.get(component);
  }

  class PropertyChangeHandler implements PropertyChangeListener {
    public void propertyChange(PropertyChangeEvent e) {
      //JTabbedPane pane = (JTabbedPane)e.getSource();
      String name = e.getPropertyName();
      if ("tabPropertyChangedAtIndex".equals(name)) {
        int index = ((Integer)e.getNewValue()).intValue();
        updateTabButtonAt(index);
      } else if ("tabPlacement".equals(name)) {
        updateTabLayoutOrientation();
      }
    }
  }

  protected void updateTabLayoutOrientation() {
    TabLayout layout = (TabLayout)tabPane.getLayout();
    int placement = tabPane.getTabPlacement();
    if (placement == JTabbedPane.TOP || placement == JTabbedPane.BOTTOM) {
      layout.setOrientation(PercentLayout.HORIZONTAL);
    } else {
      layout.setOrientation(PercentLayout.VERTICAL);
    }
  }
  
  /**
   * Manages tabs being added or removed
   */
  class ContainerTabHandler extends ContainerAdapter {

    public void componentAdded(ContainerEvent e) {
      if (!(e.getChild() instanceof UIResource)) {
        Component newTab = e.getChild();
        tabAdded(newTab);
      }
    }

    public void componentRemoved(ContainerEvent e) {
      if (!(e.getChild() instanceof UIResource)) {
        Component oldTab = e.getChild();
        tabRemoved(oldTab);
      }
    }
  }

  /**
   * Layout for the tabs, buttons get preferred size, tabs get all
   */
  protected class TabLayout extends PercentLayout {
    public void addLayoutComponent(Component component, Object constraints) {
      if (constraints == null) {
        if (component instanceof TabButton) {
          super.addLayoutComponent(component, "");
        } else {
          super.addLayoutComponent(component, "100%");
        }
      } else {
        super.addLayoutComponent(component, constraints);
      }
    }
    public void setLayoutConstraints(Container parent) {
      Component[] components = parent.getComponents();
      for (int i = 0, c = components.length; i < c; i++) {
        if (!(components[i] instanceof TabButton)) {
          super.addLayoutComponent(components[i], "100%");
        }
      }
    }
    public void layoutContainer(Container parent) {
      int selectedIndex = tabPane.getSelectedIndex();
      Component visibleComponent = getVisibleComponent();
      
      if (selectedIndex < 0) {
        if (visibleComponent != null) {
          // The last tab was removed, so remove the component
          setVisibleComponent(null);
        }
      } else {
        Component selectedComponent = tabPane.getComponentAt(selectedIndex);
        boolean shouldChangeFocus = false;

        // In order to allow programs to use a single component
        // as the display for multiple tabs, we will not change
        // the visible compnent if the currently selected tab
        // has a null component. This is a bit dicey, as we don't
        // explicitly state we support this in the spec, but since
        // programs are now depending on this, we're making it work.
        //
        if (selectedComponent != null) {
          if (selectedComponent != visibleComponent && visibleComponent != null) {
            // get the current focus owner
            Component currentFocusOwner = KeyboardFocusManager
              .getCurrentKeyboardFocusManager().getFocusOwner();
            // check if currentFocusOwner is a descendant of visibleComponent
            if (currentFocusOwner != null
              && SwingUtilities.isDescendingFrom(currentFocusOwner,
                visibleComponent)) {
              shouldChangeFocus = true;
            }
          }
          setVisibleComponent(selectedComponent);

          // make sure only the selected component is visible
          Component[] components = parent.getComponents();
          for (int i = 0; i < components.length; i++) {
            if (!(components[i] instanceof UIResource)
              && components[i].isVisible()
              && components[i] != selectedComponent) {
              components[i].setVisible(false);
              setConstraint(components[i], "*");
            }
          }
          
          if (BasicOutlookBarUI.this.nextVisibleComponent != null) {
            BasicOutlookBarUI.this.nextVisibleComponent.setVisible(true);
          }
        }

        super.layoutContainer(parent);

        if (shouldChangeFocus) {
          if (!requestFocusForVisibleComponent0()) {
            tabPane.requestFocus();
          }
        }
      }
    }
  }

  // PENDING(fred) JDK 1.5 may have this method from superclass
  protected boolean requestFocusForVisibleComponent0() {
    Component visibleComponent = getVisibleComponent();
    if (visibleComponent.isFocusable()) {
      visibleComponent.requestFocus();
      return true;
    } else if (visibleComponent instanceof JComponent) {
      if (((JComponent)visibleComponent).requestDefaultFocus()) { return true; }
    }
    return false;
  }

  protected static class TabButton extends JButton implements UIResource {
    public TabButton() {}
    public TabButton(ButtonUI ui) {
      setUI(ui);
    }
  }

  //
  //
  //

  /**
   * Overriden to return an empty adapter, the default listener was
   * just implementing the tab selection mechanism
   */
  protected MouseListener createMouseListener() {
    return new MouseAdapter() {};
  }

  /**
   * Wraps any component in a Scrollable JPanel so it can work
   * correctly within a viewport
   */
  private static class ScrollableJPanel extends JPanel implements Scrollable {
    public ScrollableJPanel(Component component) {
      setLayout(new BorderLayout(0, 0));
      add("Center", component);
      setOpaque(false);
    }
    public int getScrollableUnitIncrement(Rectangle visibleRect,
      int orientation, int direction) {
      return 16;
    }
    public Dimension getPreferredScrollableViewportSize() {
      return (super.getPreferredSize());
    }
    public int getScrollableBlockIncrement(Rectangle visibleRect,
      int orientation, int direction) {
      return 16;
    }
    public boolean getScrollableTracksViewportWidth() {
      return true;
    }
    public boolean getScrollableTracksViewportHeight() {
      return false;
    }
  }

  //
  // Override all paint methods of the BasicTabbedPaneUI to do nothing
  //

  public void paint(Graphics g, JComponent c) {}
  protected void paintContentBorder(Graphics g, int tabPlacement,
    int selectedIndex) {}
  protected void paintContentBorderBottomEdge(Graphics g, int tabPlacement,
    int selectedIndex, int x, int y, int w, int h) {}
  protected void paintContentBorderLeftEdge(Graphics g, int tabPlacement,
    int selectedIndex, int x, int y, int w, int h) {}
  protected void paintContentBorderRightEdge(Graphics g, int tabPlacement,
    int selectedIndex, int x, int y, int w, int h) {}
  protected void paintContentBorderTopEdge(Graphics g, int tabPlacement,
    int selectedIndex, int x, int y, int w, int h) {}
  protected void paintFocusIndicator(Graphics g, int tabPlacement,
    Rectangle[] rects, int tabIndex, Rectangle iconRect, Rectangle textRect,
    boolean isSelected) {}
  protected void paintIcon(Graphics g, int tabPlacement, int tabIndex,
    Icon icon, Rectangle iconRect, boolean isSelected) {}
  protected void paintTab(Graphics g, int tabPlacement, Rectangle[] rects,
    int tabIndex, Rectangle iconRect, Rectangle textRect) {}
  protected void paintTabArea(Graphics g, int tabPlacement, int selectedIndex) {}
  protected void paintTabBackground(Graphics g, int tabPlacement, int tabIndex,
    int x, int y, int w, int h, boolean isSelected) {}
  protected void paintTabBorder(Graphics g, int tabPlacement, int tabIndex,
    int x, int y, int w, int h, boolean isSelected) {}
  protected void paintText(Graphics g, int tabPlacement, Font font,
    FontMetrics metrics, int tabIndex, String title, Rectangle textRect,
    boolean isSelected) {}
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91网站在线播放| 一区二区三区资源| 欧美在线观看视频一区二区| 国产精品亚洲成人| 成人免费看黄yyy456| 丰满放荡岳乱妇91ww| 国产一区二区三区视频在线播放 | 国内精品第一页| 日本亚洲一区二区| 男人操女人的视频在线观看欧美| 亚洲va国产天堂va久久en| 亚洲欧洲综合另类| 国产视频一区不卡| 中文子幕无线码一区tr| 欧美国产日韩一二三区| 国产欧美精品一区二区三区四区 | 在线成人午夜影院| 9191成人精品久久| 3d动漫精品啪啪1区2区免费| 欧美一卡二卡在线观看| 国产女人水真多18毛片18精品视频| 久久午夜老司机| 国产精品福利一区二区三区| 亚洲最大成人网4388xx| 日本vs亚洲vs韩国一区三区 | 国产精品污www在线观看| 久久一区二区三区四区| 国产精品久久久久影院亚瑟| 亚洲777理论| 成人午夜av在线| 欧美精品在线一区二区| 日本一区二区三级电影在线观看 | 国产精品影视天天线| 色婷婷av久久久久久久| www国产精品av| 最新国产の精品合集bt伙计| 日精品一区二区| www.欧美.com| 日韩一级完整毛片| 国产精品人成在线观看免费| 午夜电影一区二区三区| 成人免费看的视频| 69p69国产精品| 日韩一区在线播放| 日韩综合在线视频| 国产精品一区专区| 欧美性xxxxxxxx| www国产亚洲精品久久麻豆| 一区二区三区免费看视频| 久久精品国产亚洲一区二区三区| www.性欧美| 欧美精品一区二区不卡| 奇米精品一区二区三区在线观看| 色嗨嗨av一区二区三区| 国产人成一区二区三区影院| 日韩福利视频导航| a在线欧美一区| 久久丝袜美腿综合| 毛片一区二区三区| 欧美精品乱人伦久久久久久| 成人欧美一区二区三区小说 | 99久久国产综合精品色伊| 久久久久久亚洲综合影院红桃| 偷拍日韩校园综合在线| 欧美在线视频日韩| 亚洲愉拍自拍另类高清精品| 91亚洲永久精品| 成人免费在线视频观看| 99久久伊人网影院| 国产精品久久毛片| av毛片久久久久**hd| 亚洲欧美在线视频| 91麻豆精品秘密| 最新日韩在线视频| 国产精品一区二区在线观看不卡| 91精品欧美综合在线观看最新 | 久久久不卡网国产精品二区| 久久国产精品免费| 精品少妇一区二区三区日产乱码| 婷婷综合在线观看| 精品日韩99亚洲| 国产一区二区中文字幕| 国产精品天干天干在观线| 99re8在线精品视频免费播放| 亚洲精品国久久99热| 欧美日韩成人综合天天影院| 奇米精品一区二区三区在线观看一| 欧美一区二区在线免费播放| 精品制服美女丁香| 国产精品入口麻豆原神| 在线观看日产精品| 日本不卡视频在线观看| 精品久久久久久久一区二区蜜臀| 国产精品1024| 国产精品久99| 91天堂素人约啪| 日韩中文字幕不卡| 精品久久国产老人久久综合| 高清久久久久久| 国产精品视频线看| 3d成人h动漫网站入口| 国产成人精品一区二区三区网站观看| 国产精品网站在线| 91精品国产综合久久久久| 国产成人免费在线| 亚洲观看高清完整版在线观看| 欧美xxxx老人做受| 色播五月激情综合网| 久99久精品视频免费观看| 亚洲免费毛片网站| 精品国产凹凸成av人网站| 一本大道av一区二区在线播放| 久久99在线观看| 夜夜嗨av一区二区三区网页| 精品国产自在久精品国产| 91久久精品日日躁夜夜躁欧美| 国内偷窥港台综合视频在线播放| 亚洲免费看黄网站| 日本一区二区免费在线| 7777精品伊人久久久大香线蕉经典版下载 | 亚洲美女电影在线| 欧美一区二区成人| 色丁香久综合在线久综合在线观看| 亚洲成av人综合在线观看| 欧美韩日一区二区三区四区| 这里只有精品免费| 成人av免费网站| 舔着乳尖日韩一区| 一区二区三区精品在线| 国产精品黄色在线观看| 久久日韩精品一区二区五区| 欧美日本不卡视频| 99久久综合狠狠综合久久| 久久99精品国产麻豆婷婷洗澡| 午夜影院在线观看欧美| 国产精品丝袜久久久久久app| 日韩一级免费一区| 欧美精品久久一区二区三区| 99精品国产视频| 国产精品 日产精品 欧美精品| 日本在线不卡一区| 美腿丝袜亚洲一区| 美女高潮久久久| 日韩成人伦理电影在线观看| 亚洲成人自拍偷拍| 午夜天堂影视香蕉久久| 亚洲国产欧美一区二区三区丁香婷| 国产日韩欧美不卡| 国产性色一区二区| 国产欧美精品在线观看| 国产日韩精品一区二区三区在线| 国产日韩精品一区二区三区| 精品女同一区二区| 日韩欧美国产午夜精品| 欧美一二三四区在线| 日韩欧美国产三级| 欧美本精品男人aⅴ天堂| 日韩一区二区视频| ww亚洲ww在线观看国产| 国产欧美综合色| 国产日韩成人精品| 国产精品不卡视频| 综合欧美一区二区三区| 亚洲国产日韩一级| 久久99热狠狠色一区二区| 国产一区在线观看麻豆| 成人av综合一区| 欧美丝袜丝交足nylons图片| 欧美美女视频在线观看| 精品福利一区二区三区| 国产精品久久久久久久岛一牛影视 | 成av人片一区二区| 91福利在线导航| 日韩美女天天操| 国产精品久久午夜| 亚洲成av人片www| 激情久久五月天| eeuss国产一区二区三区| 欧美亚洲丝袜传媒另类| 亚洲精品一区二区三区影院| 亚洲少妇30p| 另类小说视频一区二区| yourporn久久国产精品| 欧美精三区欧美精三区| 国产精品视频yy9299一区| 亚洲电影欧美电影有声小说| 国精产品一区一区三区mba桃花| 色婷婷av久久久久久久| 精品欧美一区二区在线观看| 亚洲六月丁香色婷婷综合久久| 久久国产精品第一页| 色偷偷成人一区二区三区91| xnxx国产精品| 日日噜噜夜夜狠狠视频欧美人| 成人一二三区视频| 欧美草草影院在线视频| 一区二区欧美在线观看| 国产成人久久精品77777最新版本| 欧美色精品天天在线观看视频| 国产日韩v精品一区二区|