parameters: (self, update_type=None, new_state_machine=False, given_tree_iter=None)
docstring: Window title preceeded by an asterix
docstring_summary: Window title preceeded by an asterix
docstring_tokens: Window title preceeded by an asterix
function: def update_window_save_needed(self, update_type=None, new_state_machine=False, given_tree_iter=None):
          """Window title preceeded by an asterix"""
          tree_iter = self.curr_tree_iter if not given_tree_iter else given_tree_iter
          if tree_iter and self.treestore[tree_iter][4] == cons.RICH_TEXT_ID:
              self.treestore[tree_iter][2].set_modified(True)
          if not self.file_update:
              self.window_title_update(True)
              self.file_update = True
          if update_type:
              if update_type == "nbuf":
                  if tree_iter:
                      node_id = self.get_node_id_from_tree_iter(tree_iter)
                      self.ctdb_handler.pending_edit_db_node_buff(node_id)
                      curr_time = time.time()
                      self.treestore[tree_iter][13] = curr_time
                      if (not node_id in self.latest_statusbar_update_time.keys())\
                      or (curr_time - self.latest_statusbar_update_time[node_id] > 60):
                          self.latest_statusbar_update_time[node_id] = curr_time
                          self.update_selected_node_statusbar_info()
              elif update_type == "npro":
                  if tree_iter:
                      self.ctdb_handler.pending_edit_db_node_prop(self.treestore[tree_iter][3])
              elif update_type == "ndel":
                  if tree_iter:
                      # the removal will also affect children
                      top_node_id = self.get_node_id_from_tree_iter(tree_iter)
                      for node_id in ([top_node_id] + self.get_children_node_ids(tree_iter)):
                          self.ctdb_handler.pending_rm_db_node(node_id)
                          self.state_machine.delete_states(node_id)
              elif update_type == "book": self.ctdb_handler.pending_edit_db_bookmarks()
          if new_state_machine and tree_iter:
              self.state_machine.update_state()
function_tokens: def update_window_save_needed ( self , update_type = None , new_state_machine = False , given_tree_iter = None ) : tree_iter = self . curr_tree_iter if not given_tree_iter else given_tree_iter if tree_iter and self . treestore [ tree_iter ] [ 4 ] == cons . RICH_TEXT_ID : self . treestore [ tree_iter ] [ 2 ] . set_modified ( True ) if not self . file_update : self . window_title_update ( True ) self . file_update = True if update_type : if update_type == "nbuf" : if tree_iter : node_id = self . get_node_id_from_tree_iter ( tree_iter ) self . ctdb_handler . pending_edit_db_node_buff ( node_id ) curr_time = time . time ( ) self . treestore [ tree_iter ] [ 13 ] = curr_time if ( not node_id in self . latest_statusbar_update_time . keys ( ) ) or ( curr_time - self . latest_statusbar_update_time [ node_id ] > 60 ) : self . latest_statusbar_update_time [ node_id ] = curr_time self . update_selected_node_statusbar_info ( ) elif update_type == "npro" : if tree_iter : self . ctdb_handler . pending_edit_db_node_prop ( self . treestore [ tree_iter ] [ 3 ] ) elif update_type == "ndel" : if tree_iter : # the removal will also affect children top_node_id = self . get_node_id_from_tree_iter ( tree_iter ) for node_id in ( [ top_node_id ] + self . get_children_node_ids ( tree_iter ) ) : self . ctdb_handler . pending_rm_db_node ( node_id ) self . state_machine . delete_states ( node_id ) elif update_type == "book" : self . ctdb_handler . pending_edit_db_bookmarks ( ) if new_state_machine and tree_iter : self . state_machine . update_state ( )