From: Nando D. <na...@us...> - 2004-09-16 11:37:43
|
Update of /cvsroot/instantobjects/Source/Brokers/IBX In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5636/Brokers/IBX Modified Files: InstantIBXConnectionDefEdit.dfm InstantIBXConnectionDefEdit.pas Log Message: Support for changing the data type and size used for ID fields. Index: InstantIBXConnectionDefEdit.dfm =================================================================== RCS file: /cvsroot/instantobjects/Source/Brokers/IBX/InstantIBXConnectionDefEdit.dfm,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** InstantIBXConnectionDefEdit.dfm 29 Jul 2004 20:43:14 -0000 1.2 --- InstantIBXConnectionDefEdit.dfm 16 Sep 2004 11:37:33 -0000 1.3 *************** *** 4,8 **** BorderStyle = bsDialog Caption = 'InterBase Connection' ! ClientHeight = 393 ClientWidth = 362 Color = clBtnFace --- 4,8 ---- BorderStyle = bsDialog Caption = 'InterBase Connection' ! ClientHeight = 399 ClientWidth = 362 Color = clBtnFace *************** *** 19,23 **** object BottomBevel: TBevel Left = 0 ! Top = 356 Width = 362 Height = 2 --- 19,23 ---- object BottomBevel: TBevel Left = 0 ! Top = 362 Width = 362 Height = 2 *************** *** 29,33 **** Top = 0 Width = 362 ! Height = 356 Align = alClient BevelOuter = bvNone --- 29,33 ---- Top = 0 Width = 362 ! Height = 362 Align = alClient BevelOuter = bvNone *************** *** 59,63 **** object StreamFormatLabel: TLabel Left = 16 ! Top = 310 Width = 53 Height = 13 --- 59,63 ---- object StreamFormatLabel: TLabel Left = 16 ! Top = 312 Width = 53 Height = 13 *************** *** 73,76 **** --- 73,92 ---- FocusControl = ParamsEditor end + object Label1: TLabel + Left = 136 + Top = 312 + Width = 62 + Height = 13 + Caption = 'Id Data Type' + FocusControl = IdDataTypeComboBox + end + object Label2: TLabel + Left = 256 + Top = 312 + Width = 32 + Height = 13 + Caption = 'Id Size' + FocusControl = IdDataTypeComboBox + end object LocalRadioButton: TRadioButton Left = 16 *************** *** 131,136 **** object StreamFormatComboBox: TComboBox Left = 16 ! Top = 326 ! Width = 150 Height = 21 Style = csDropDownList --- 147,152 ---- object StreamFormatComboBox: TComboBox Left = 16 ! Top = 328 ! Width = 113 Height = 21 Style = csDropDownList *************** *** 162,169 **** TabOrder = 8 end end object BottomPanel: TPanel Left = 0 ! Top = 358 Width = 362 Height = 35 --- 178,201 ---- TabOrder = 8 end + object IdDataTypeComboBox: TComboBox + Left = 136 + Top = 328 + Width = 113 + Height = 21 + Style = csDropDownList + ItemHeight = 13 + TabOrder = 10 + end + object IdSizeEdit: TEdit + Left = 256 + Top = 328 + Width = 89 + Height = 21 + TabOrder = 11 + end end object BottomPanel: TPanel Left = 0 ! Top = 364 Width = 362 Height = 35 *************** *** 171,174 **** --- 203,209 ---- BevelOuter = bvNone TabOrder = 1 + DesignSize = ( + 362 + 35) object OkButton: TButton Left = 204 Index: InstantIBXConnectionDefEdit.pas =================================================================== RCS file: /cvsroot/instantobjects/Source/Brokers/IBX/InstantIBXConnectionDefEdit.pas,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** InstantIBXConnectionDefEdit.pas 29 Jul 2004 20:43:14 -0000 1.2 --- InstantIBXConnectionDefEdit.pas 16 Sep 2004 11:37:33 -0000 1.3 *************** *** 26,30 **** * Contributor(s): * Carlo Barazzetta: blob streaming in XML format (Part, Parts, References) ! * * ***** END LICENSE BLOCK ***** *) --- 26,31 ---- * Contributor(s): * Carlo Barazzetta: blob streaming in XML format (Part, Parts, References) ! * Nando Dessena: ! * - Support for changing the data type used for ID fields. * ***** END LICENSE BLOCK ***** *) *************** *** 59,62 **** --- 60,67 ---- ParamsLabel: TLabel; ParamsEditor: TMemo; + IdDataTypeComboBox: TComboBox; + Label1: TLabel; + IdSizeEdit: TEdit; + Label2: TLabel; procedure LocalRemoteChange(Sender: TObject); procedure DatabaseButtonClick(Sender: TObject); *************** *** 76,80 **** uses ! IB, InstantPersistence, InstantClasses; { TInstantIBXConnectionDefEditForm } --- 81,85 ---- uses ! IB, InstantPersistence, InstantClasses, InstantConsts; { TInstantIBXConnectionDefEditForm } *************** *** 98,102 **** procedure TInstantIBXConnectionDefEditForm.FormCreate(Sender: TObject); begin ! AssignInstantStreamFormat(StreamFormatComboBox.Items); //CB UpdateControls; end; --- 103,110 ---- procedure TInstantIBXConnectionDefEditForm.FormCreate(Sender: TObject); begin ! AssignInstantStreamFormat(StreamFormatComboBox.Items); ! AssignInstantDataTypeStrings(IdDataTypeComboBox.Items); ! IdDataTypeComboBox.ItemIndex := Ord(dtString); ! IdSizeEdit.Text := IntToStr(InstantDefaultFieldSize); UpdateControls; end; *************** *** 119,127 **** ServerEdit.Text := ServerName; DatabaseEdit.Text := Path; - //CB StreamFormatComboBox.ItemIndex := Ord(BlobStreamFormat); UseDelimitedIdentsCheckBox.Checked := ibxUseDelimitedIdents in Options; LoginPromptCheckBox.Checked := LoginPrompt; ParamsEditor.Lines.Text := ConnectionDef.Params; end; UpdateControls; --- 127,136 ---- ServerEdit.Text := ServerName; DatabaseEdit.Text := Path; StreamFormatComboBox.ItemIndex := Ord(BlobStreamFormat); UseDelimitedIdentsCheckBox.Checked := ibxUseDelimitedIdents in Options; LoginPromptCheckBox.Checked := LoginPrompt; ParamsEditor.Lines.Text := ConnectionDef.Params; + IdDataTypeComboBox.ItemIndex := Ord(IdDataType); + IdSizeEdit.Text := IntToStr(IdSize); end; UpdateControls; *************** *** 145,149 **** ServerName := ServerEdit.Text; Path := DatabaseEdit.Text; - //CB BlobStreamFormat := TInstantStreamFormat(StreamFormatComboBox.ItemIndex); Options := []; --- 154,157 ---- *************** *** 152,155 **** --- 160,165 ---- LoginPrompt := LoginPromptCheckBox.Checked; ConnectionDef.Params := ParamsEditor.Lines.Text; + IdDataType := TInstantDataType(IdDataTypeComboBox.ItemIndex); + IdSize := StrToInt(IdSizeEdit.Text); end; end; |