/[thuban]/branches/WIP-pyshapelib-bramz/Thuban/UI/identifyview.py
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/Thuban/UI/identifyview.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1706 by jan, Wed Sep 3 08:31:26 2003 UTC revision 1968 by bh, Fri Nov 21 14:33:27 2003 UTC
# Line 16  from Thuban import _ Line 16  from Thuban import _
16  from dialogs import NonModalDialog  from dialogs import NonModalDialog
17  from controls import RecordListCtrl, RecordGridCtrl  from controls import RecordListCtrl, RecordGridCtrl
18  from messages import SHAPES_SELECTED  from messages import SHAPES_SELECTED
19    import main
20    
21  class IdentifyListCtrl(RecordListCtrl):  class IdentifyListCtrl(RecordListCtrl):
22    
# Line 44  class IdentifyView(NonModalDialog): Line 45  class IdentifyView(NonModalDialog):
45          parent.Subscribe(SHAPES_SELECTED, self.selected_shape)          parent.Subscribe(SHAPES_SELECTED, self.selected_shape)
46    
47          top_box = wxBoxSizer(wxVERTICAL)          top_box = wxBoxSizer(wxVERTICAL)
48          #self.list = IdentifyGridCtrl(panel)          if main.options.attribute_editing_enabled:
49          self.list = IdentifyListCtrl(self, -1)              self.list = IdentifyGridCtrl(self)
50            else:
51                self.list = IdentifyListCtrl(self, -1)
52          self.list.SetSize(wxSize(305,200))          self.list.SetSize(wxSize(305,200))
53          top_box.Add(self.list, 1, wxEXPAND|wxALL, 4)          top_box.Add(self.list, 1, wxEXPAND|wxALL, 4)
54    
# Line 78  class IdentifyView(NonModalDialog): Line 81  class IdentifyView(NonModalDialog):
81      def selected_shape(self, layer, shapes):      def selected_shape(self, layer, shapes):
82          """Subscribed to the SHAPES_SELECTED messages.          """Subscribed to the SHAPES_SELECTED messages.
83    
84          If exatly one shape is selected, pass that shape id to the          If exactly one shape is selected, pass that shape id to the
85          list's selected_shape method. Otherwise pass None as the shape          list's selected_shape method. Otherwise pass None as the shape
86          id.          id.
87          """          """

Legend:
Removed from v.1706  
changed lines
  Added in v.1968

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26