1 |
2003-04-25 Jonathan Coles <[email protected]> |
2003-04-25 Jonathan Coles <[email protected]> |
2 |
|
|
3 |
|
* Thuban/Model/proj.py (Projection): Removed Set*() methods to make |
4 |
|
Projection an immutable item. Fixes RTbug #1825. |
5 |
|
(Projection.__init__): Initialize instance variables here. |
6 |
|
(ProjFile.Replace): New. Replace the given projection object with |
7 |
|
the new projection object. This solves the problem of needing the |
8 |
|
mutator Projection.SetProjection() in the ProjFrame class and |
9 |
|
allows a projection to change parameters without changing its |
10 |
|
location in the file. |
11 |
|
|
12 |
|
* Thuban/UI/mainwindow.py (MainWindow.SaveSessionAs): Dialog should |
13 |
|
be of type wxSAVE and should verify overwriting a file. |
14 |
|
|
15 |
|
* Thuban/UI/projdialog.py (ProjFrame._OnSave): Use the new |
16 |
|
ProjFile.Replace() method instead of the mutator |
17 |
|
Projection.SetProjection(). Also requires that we reassign the |
18 |
|
client data to the new projection. |
19 |
|
|
20 |
|
* test/test_proj.py (TestProjection.test): Test GetName() and |
21 |
|
GetAllParameters() |
22 |
|
(TestProjFile.test): Remove tests for Set*() methods. Add tests |
23 |
|
for Replace(). |
24 |
|
|
25 |
|
2003-04-25 Jonathan Coles <[email protected]> |
26 |
|
|
27 |
|
* Thuban/Model/save.py (SessionSaver.write_projection): Make sure |
28 |
|
to save the name of the projection. |
29 |
|
|
30 |
|
* test/test_save.py (SaveSessionTest.testLayerProjection): New |
31 |
|
test to verify layer projections are saved correctly. |
32 |
|
|
33 |
|
2003-04-25 Jonathan Coles <[email protected]> |
34 |
|
|
35 |
|
* Thuban/Model/proj.py (Projection.SetName): Set the name |
36 |
|
to "Unknown" if name is None. |
37 |
|
(Projection.SetAllParameters): New. Set the projection's |
38 |
|
parameter list to the one supplied. |
39 |
|
(Projection.SetProjection): New. Set the projection's |
40 |
|
properties to those of the supplied Projection. |
41 |
|
|
42 |
|
* Thuban/UI/mainwindow.py (MainWindow.MapProjection): Set |
43 |
|
the dialog title to include the map's title. |
44 |
|
(MainWindow.LayerProjection): Set the dialog title to include |
45 |
|
the layer's title. |
46 |
|
|
47 |
|
* Thuban/UI/projdialog.py (ProjFrame.__ShowError): Consolidate |
48 |
|
error dialogs into a single method call. |
49 |
|
(ProjFrame.__VerifyButtons): Add more states to check. |
50 |
|
(ProjFrame.__GetProjection): Return the current state of an |
51 |
|
edited projection or None. |
52 |
|
(ProjFrame.__FillAvailList): Remove checks for states that |
53 |
|
shouldn't exist. |
54 |
|
(ProjFrame._OnNew): Clear all selected items and supply |
55 |
|
a projection panel if necessary. |
56 |
|
|
57 |
|
* test/test_proj.py (TestProjFile.test): Add tests for |
58 |
|
ProjFile.SetAllParameters, ProjFile.SetProjection, |
59 |
|
ProjFile.SetName. |
60 |
|
|
61 |
|
2003-04-25 Jonathan Coles <[email protected]> |
62 |
|
|
63 |
|
* Thuban/UI/projdialog.py (ProjFrame.__FillAvailList): Now |
64 |
|
takes an optional argument to select the current projection. |
65 |
|
This does not guarantee that the item is visible due to |
66 |
|
limited wxWindows functionality. Fixes RTBug #1821. |
67 |
|
|
68 |
|
2003-04-25 Jonathan Coles <[email protected]> |
69 |
|
|
70 |
|
* Thuban/Model/load.py (SessionLoader.start_projection): Remember |
71 |
|
the projection name and use it when constructing the Projection |
72 |
|
object. |
73 |
|
|
74 |
|
* Thuban/Model/proj.py (Projection.__init__): Change the default |
75 |
|
value for 'name' to None and then test if name is equal to None |
76 |
|
in the body of the constructor. This way the caller doesn't have to |
77 |
|
know what the default value should be. Namely, useful in load.py |
78 |
|
where we have to pick a default value if the 'name' parameter |
79 |
|
doesn't exist in the XML file. |
80 |
|
|
81 |
|
* test/test_load.py (LoadSessionTest.testLayerProjection): New. |
82 |
|
Tests a file where a layer has a projection. |
83 |
|
|
84 |
|
2003-04-25 Jonathan Coles <[email protected]> |
85 |
|
|
86 |
* Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the |
* Thuban/Model/layer.py (Layer.TreeInfo): Add an item to the |
87 |
tree for projection information. |
tree for projection information. |
88 |
|
|