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

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

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

revision 2102 by bh, Thu Mar 11 21:04:30 2004 UTC revision 2184 by jan, Fri Apr 16 08:21:12 2004 UTC
# Line 629  class MainWindow(DockFrame): Line 629  class MainWindow(DockFrame):
629          return layer is not None and hasattr(layer, "ShapeStore")          return layer is not None and hasattr(layer, "ShapeStore")
630    
631      def LayerShowTable(self):      def LayerShowTable(self):
632            """
633            Present a TableView Window for the current layer.
634            In case the window is already open, bring it to the front.
635            In case, there is no active layer, do nothing.
636            In case, the layer has not ShapeStore, raise a corresponding message dialog
637            and do nothing else.
638            """
639          layer = self.current_layer()          layer = self.current_layer()
640          if layer is not None:          if layer is not None:
641                if not hasattr(layer, "ShapeStore"):
642                    self.RunMessageBox(_("Show Table"),
643                                       _("The layer '%s' has no table." % layer.Title()))
644                    return
645              table = layer.ShapeStore().Table()              table = layer.ShapeStore().Table()
646              name = "table_view" + str(id(table))              name = "table_view" + str(id(table))
647              dialog = self.get_open_dialog(name)              dialog = self.get_open_dialog(name)
# Line 641  class MainWindow(DockFrame): Line 652  class MainWindow(DockFrame):
652                  self.add_dialog(name, dialog)                  self.add_dialog(name, dialog)
653                  dialog.Show(True)                  dialog.Show(True)
654              else:              else:
655                  # FIXME: bring dialog to front here                  dialog.Raise()
                 pass  
656    
657      def MapProjection(self):      def MapProjection(self):
658    

Legend:
Removed from v.2102  
changed lines
  Added in v.2184

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26