Sha256: 95069c5b277441a7c5412eeb1bb2dc3a573e01fd3880022a181ab8f251afc13d

Contents?: true

Size: 767 Bytes

Versions: 2

Compression:

Stored size: 767 Bytes

Contents

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

# Advanced User Interface Notebook - draggable panes etc

class Wx::AUI::AuiNotebook

  # Before wxWidgets 3.3 the AUI manager of this control would prevent
  # WindowDestroyEvent propagation so we 'patch' in a std event handler
  # that designates the event skipped.
  if Wx::WXWIDGETS_VERSION < '3.3'
    wx_initialize = instance_method :initialize
    define_method :initialize do |*args|
      wx_initialize.bind(self).call(*args)
      evt_window_destroy { |evt| evt.skip }
    end
  end

  # Convenience method for iterating pages
  def each_page
    0.upto(get_page_count - 1) do | i |
      yield get_page(i)
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
wxruby3-0.9.1-x64-mingw-ucrt lib/wx/aui/auinotebook.rb
wxruby3-0.9.0-x64-mingw-ucrt lib/wx/aui/auinotebook.rb