Sha256: 44ff23149158ba6e51aeeb8649d5c3feeebfabd640b404ff70a8c0597c4fb8b7

Contents?: true

Size: 413 Bytes

Versions: 28

Compression:

Stored size: 413 Bytes

Contents

class Wx::Clipboard
  class << self
    # Class method to provide access to the clipboard within a ruby
    # block. Tests that the clipboard could be accessed, and ensures
    # that it is closed when the block is finished.
    def open
      clip = Wx::Clipboard.new
      unless clip.open
        Kernel.raise "Could not open clipboard"
      end
      yield clip
    ensure
      clip.close
    end
  end
end

Version data entries

28 entries across 28 versions & 2 rubygems

Version Path
wxruby-1.9.7-i386-mswin32 lib/wx/classes/clipboard.rb
wxruby-1.9.5-i386-mswin32 lib/wx/classes/clipboard.rb
wxruby-1.9.4-i386-mswin32 lib/wx/classes/clipboard.rb
wxruby-1.9.3-i386-mswin32 lib/wx/classes/clipboard.rb
wxruby-1.9.3-universal-darwin lib/wx/classes/clipboard.rb
wxruby-1.9.3-x86-linux lib/wx/classes/clipboard.rb
wxruby-1.9.4-x86_64-linux lib/wx/classes/clipboard.rb
wxruby-1.9.4-x86-linux lib/wx/classes/clipboard.rb
wxruby-1.9.5-universal-darwin-9 lib/wx/classes/clipboard.rb
wxruby-1.9.5-x86-linux lib/wx/classes/clipboard.rb
wxruby-1.9.5-x86_64-linux lib/wx/classes/clipboard.rb
wxruby-1.9.6-universal-darwin-9 lib/wx/classes/clipboard.rb
wxruby-1.9.6-x86-linux lib/wx/classes/clipboard.rb
wxruby-1.9.6-x86-mingw32 lib/wx/classes/clipboard.rb
wxruby-1.9.6-x86-mswin32-60 lib/wx/classes/clipboard.rb
wxruby-1.9.7-universal-darwin-9 lib/wx/classes/clipboard.rb
wxruby-1.9.7-x86-mswin32-60 lib/wx/classes/clipboard.rb
wxruby-1.9.7-x86-linux lib/wx/classes/clipboard.rb
wxruby-1.9.8-universal-darwin-9 lib/wx/classes/clipboard.rb
wxruby-1.9.8-x86-mingw32 lib/wx/classes/clipboard.rb