Sha256: 3f222cea8550674ff48c4a415a7c7205c772e0edf59132e944554bda4d744b00

Contents?: true

Size: 1.57 KB

Versions: 11

Compression:

Stored size: 1.57 KB

Contents

# :stopdoc:
# Copyright (c) 2023 M.J.N. Corino, The Netherlands
#
# This software is released under the MIT license.
# :startdoc:


module Wx

  # Function used to create the correct persistent adapter for the given object.
  #
  # This is a compatibility function that simply redirects the call to the object itself. Any object class
  # supporting persistence should implement the #create_persistent_object method to return a Wx::PersistentObject
  # instance for the object it is called for.
  # This method raises a NoImplementError if the object class does not support persistence.
  # @see Defining Custom Persistent Windows
  # @param obj [::Object]
  # @return [Wx::PersistentObject]
  def self.create_persistent_object(obj) end

  # A shorter synonym for {Wx::PersistenceManager#register_and_restore}.
  #
  # This function simply calls {Wx::PersistenceManager#register_and_restore} but using it results in slightly shorter
  # code as it calls {Wx::PersistenceManager.get} internally. As an additional convenience, this function can also set the window name.
  #
  # Returns true if the settings were restored or false otherwise (this will always be the case when the program runs
  # for the first time, for example).
  # @param obj [Wx::Window]  window to register with persistence manager and to try to restore the settings for.
  # @param name [String]  If specified non-empty, window name is changed to the provided value before registering it.
  # @return [Boolean]
  def self.persistent_register_and_restore(obj, name=nil) end

  # class alias
  PersistentWindow = PersistentWindowBase

end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
wxruby3-1.4.2 lib/wx/doc/persistence_manager.rb
wxruby3-1.4.1 lib/wx/doc/persistence_manager.rb
wxruby3-1.4.0 lib/wx/doc/persistence_manager.rb
wxruby3-1.3.1 lib/wx/doc/persistence_manager.rb
wxruby3-1.3.0 lib/wx/doc/persistence_manager.rb
wxruby3-1.2.1 lib/wx/doc/persistence_manager.rb
wxruby3-1.2.0 lib/wx/doc/persistence_manager.rb
wxruby3-1.1.2 lib/wx/doc/persistence_manager.rb
wxruby3-1.1.1 lib/wx/doc/persistence_manager.rb
wxruby3-1.1.0 lib/wx/doc/persistence_manager.rb
wxruby3-1.0.1 lib/wx/doc/persistence_manager.rb