@ -7,6 +7,7 @@ import com.fr.data.impl.JDBCDatabaseConnection;
import com.fr.design.border.UITitledBorder ;
import com.fr.design.gui.ibutton.UIButton ;
import com.fr.design.gui.icombobox.UIComboBox ;
import com.fr.design.gui.icombobox.UIComboBoxUI ;
import com.fr.design.gui.ilable.ActionLabel ;
import com.fr.design.gui.ilable.UILabel ;
import com.fr.design.gui.ipasswordfield.UIPasswordFieldWithFixedLength ;
@ -32,6 +33,8 @@ import javax.swing.JPanel;
import javax.swing.JPasswordField ;
import javax.swing.event.DocumentEvent ;
import javax.swing.event.DocumentListener ;
import javax.swing.plaf.ComboBoxUI ;
import javax.swing.plaf.basic.ComboPopup ;
import java.awt.BorderLayout ;
import java.awt.Color ;
import java.awt.Component ;
@ -275,8 +278,9 @@ public class JDBCDefPane extends JPanel {
}
dbtypeComboBox . addActionListener ( dbtypeActionListener ) ;
dbtypeComboBox . setMaximumRowCount ( 10 ) ;
driverLoaderBox = new UIComboBox ( ) ;
driverLoaderBox = new Special UIComboBox( ) ;
refreshDriverLoader ( ) ;
driverLoaderBox . setPreferredSize ( new Dimension ( 200 , driverLoaderBox . getPreferredSize ( ) . height ) ) ;
driverLoaderBox . setEditable ( false ) ;
driverManageBox = new UIComboBox ( ) ;
refreshDriverManage ( true ) ;
@ -350,7 +354,7 @@ public class JDBCDefPane extends JPanel {
odbcTipsPane . add ( driverManageLabel ) ;
odbcTipsPane . add ( odbcTipsLink ) ;
JPanel driverComboBoxAndTips = new JPanel ( new BorderLayout ( ) ) ;
JPanel normalFlowInnerContainer_s_pane = FRGUIPaneFactory . createNormalFlowInnerContainer_S_Pane ( ) ;
JPanel normalFlowInnerContainer_s_pane = FRGUIPaneFactory . createBoxFlowInnerContainer_S_Pane ( 0 , 5 , 0 ) ;
normalFlowInnerContainer_s_pane . add ( driverManageBox ) ;
normalFlowInnerContainer_s_pane . add ( driverComboBox ) ;
normalFlowInnerContainer_s_pane . add ( driverLoaderBox ) ;
@ -717,4 +721,22 @@ public class JDBCDefPane extends JPanel {
private String driver ;
private String url ;
}
private static class SpecialUIComboBox extends UIComboBox {
@Override
public ComboBoxUI getUIComboBoxUI ( ) {
return new SpecialUIComboBoxUI ( ) ;
}
}
private static class SpecialUIComboBoxUI extends UIComboBoxUI {
@Override
public ComboPopup createPopup ( ) {
return createHorizontalNeverUIComboPopUp ( ) ;
}
}
}