diff --git a/Project1.dproj b/Project1.dproj
index 8cb1a38..49a329e 100644
--- a/Project1.dproj
+++ b/Project1.dproj
@@ -157,12 +157,27 @@
true
-
+
+
+ 0
+ .dll;.bpl
+
1
+ .dylib
+
+
+ Contents\MacOS
+ 1
+ .dylib
1
+ .dylib
+
+
+ 1
+ .dylib
@@ -516,27 +531,12 @@
1
-
-
- 0
- .dll;.bpl
-
+
1
- .dylib
-
-
- Contents\MacOS
- 1
- .dylib
1
- .dylib
-
-
- 1
- .dylib
diff --git a/Project1.dproj.local b/Project1.dproj.local
index ef0cd7f..2e6cb3c 100644
--- a/Project1.dproj.local
+++ b/Project1.dproj.local
@@ -15,8 +15,8 @@
2018/08/02 11:51:22.000.511,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormCidade.pas
2018/08/02 11:54:03.000.448,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj
2018/08/03 07:57:41.000.908,=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas
- 2018/08/03 07:59:28.000.101,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormEstado.pas
2018/08/03 07:59:28.000.101,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.dfm=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormEstado.dfm
+ 2018/08/03 07:59:28.000.101,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormEstado.pas
2018/08/03 09:19:04.000.339,=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas
2018/08/03 09:22:08.000.430,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormPais.pas=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.pas
2018/08/03 09:22:08.000.430,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\UnitFormPais.dfm=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Unit1.dfm
@@ -38,6 +38,7 @@
2018/08/15 15:04:40.000.526,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj
2018/08/16 11:06:43.000.602,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj
2018/08/17 12:26:51.000.000,C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj=C:\Users\programacaounico38\Documents\Embarcadero\Studio\Projects\Ex_CRUD\Project1.dproj
+ 2018/08/21 09:38:54.903,C:\Users\programacaounico38\Documents\Projects\crud_delphi\Project1.dproj=C:\Users\programacaounico38\Documents\Projects\crud_delphi\Project1.dproj
diff --git a/Project1.stat b/Project1.stat
index bb9ae40..3f2e110 100644
--- a/Project1.stat
+++ b/Project1.stat
@@ -1,10 +1,10 @@
[Stats]
-EditorSecs=55178
-DesignerSecs=6472
-InspectorSecs=2098
-CompileSecs=327581
-OtherSecs=2039
+EditorSecs=55299
+DesignerSecs=6553
+InspectorSecs=2305
+CompileSecs=338405
+OtherSecs=1803
StartTime=03/08/2018 07:57:26
RealKeys=0
EffectiveKeys=0
-DebugSecs=23926
+DebugSecs=24770
diff --git a/UnitFormCidade.dfm b/UnitFormCidade.dfm
index 27040f1..99b166f 100644
--- a/UnitFormCidade.dfm
+++ b/UnitFormCidade.dfm
@@ -18,7 +18,6 @@ inherited FormCidade: TFormCidade
OnClick = btBuscarClick
end
inherited btInserir: TButton
- Default = False
OnClick = btInserirClick
end
inherited btExcluir: TButton
@@ -37,14 +36,12 @@ inherited FormCidade: TFormCidade
inherited Panel1: TPanel
Height = 264
ExplicitHeight = 264
- inherited cbLimparCampos: TCheckBox
- TabOrder = 1
- end
inherited Panel2: TPanel
+ Left = 99
Top = 6
- TabOrder = 0
- ExplicitLeft = 98
- object Label1: TLabel
+ ExplicitLeft = 99
+ ExplicitTop = 6
+ object Label1: TLabel [0]
Left = 52
Top = 66
Width = 42
@@ -52,7 +49,7 @@ inherited FormCidade: TFormCidade
Anchors = []
Caption = 'C'#243'digo:'
end
- object Label2: TLabel
+ object Label2: TLabel [1]
Left = 54
Top = 111
Width = 40
@@ -60,7 +57,7 @@ inherited FormCidade: TFormCidade
Anchors = []
Caption = 'Cidade:'
end
- object Label3: TLabel
+ object Label3: TLabel [2]
Left = 69
Top = 161
Width = 25
@@ -68,7 +65,7 @@ inherited FormCidade: TFormCidade
Anchors = []
Caption = 'Pa'#237's:'
end
- object Label4: TLabel
+ object Label4: TLabel [3]
Left = 277
Top = 161
Width = 19
@@ -76,6 +73,10 @@ inherited FormCidade: TFormCidade
Anchors = []
Caption = 'UF:'
end
+ inherited cbLimparCampos: TCheckBox
+ TabOrder = 4
+ OnClick = cbLimparCamposClick
+ end
object edCidade: TEdit
Tag = 1
Left = 109
diff --git a/UnitFormCidade.pas b/UnitFormCidade.pas
index f9c09f4..0f99fd5 100644
--- a/UnitFormCidade.pas
+++ b/UnitFormCidade.pas
@@ -370,6 +370,8 @@ begin
begin
wAux := 1;
wLista.Update(I, Cidade);
+ if wClear then
+ limpaCampos();
break;
end
else
@@ -377,10 +379,17 @@ begin
end;
end;
if wAux =0 then
- wLista.Inserir(Cidade, TCidade)
+ begin
+ wLista.Inserir(Cidade, TCidade);
+ if wClear then
+ limpaCampos();
+ end;
+
end
else
wLista.Inserir(Cidade, TCidade);
+ if wClear then
+ limpaCampos();
end;
end;
diff --git a/UnitFormPadrao.dfm b/UnitFormPadrao.dfm
index 6fc75f5..1f5fa7e 100644
--- a/UnitFormPadrao.dfm
+++ b/UnitFormPadrao.dfm
@@ -22,71 +22,87 @@ object FormPadrao: TFormPadrao
Top = 0
Width = 598
Height = 29
+ ButtonHeight = 20
Caption = 'ToolBar1'
TabOrder = 0
object btAnterior: TButton
Left = 0
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = '<'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 0
end
object btProximo: TButton
Left = 75
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = '>'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 1
end
object btBuscar: TButton
Left = 150
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Buscar'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 2
end
object btInserir: TButton
Left = 225
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Inserir'
- Default = True
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 3
end
object btExcluir: TButton
Left = 300
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Excluir'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 4
end
object btImportar: TButton
Left = 375
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Importar'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 5
end
object btExportar: TButton
Left = 450
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Exportar'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 6
end
object btContar: TButton
Left = 525
Top = 0
Width = 75
- Height = 22
+ Height = 20
Caption = 'Contar'
+ DoubleBuffered = False
+ ParentDoubleBuffered = False
TabOrder = 7
end
end
@@ -101,8 +117,8 @@ object FormPadrao: TFormPadrao
598
284)
object Panel2: TPanel
- Left = 98
- Top = 16
+ Left = 354
+ Top = 296
Width = 400
Height = 250
Anchors = []
diff --git a/Win32/Debug/Project1.exe b/Win32/Debug/Project1.exe
index 5347cc0..e51a305 100644
Binary files a/Win32/Debug/Project1.exe and b/Win32/Debug/Project1.exe differ
diff --git a/Win32/Debug/UnitFormCidade.dcu b/Win32/Debug/UnitFormCidade.dcu
index 97b5905..2c62b13 100644
Binary files a/Win32/Debug/UnitFormCidade.dcu and b/Win32/Debug/UnitFormCidade.dcu differ
diff --git a/Win32/Debug/UnitFormPadrao.dcu b/Win32/Debug/UnitFormPadrao.dcu
index 470832d..f15e1f9 100644
Binary files a/Win32/Debug/UnitFormPadrao.dcu and b/Win32/Debug/UnitFormPadrao.dcu differ