Sha256: c282bf2bfffe37b0d6f91cd2f137a5517c65e2e1ee29d53e1e5457ca24f96179
Contents?: true
Size: 1.17 KB
Versions: 16
Compression:
Stored size: 1.17 KB
Contents
# Copyright (c) 2023 M.J.N. Corino, The Netherlands # # This software is released under the MIT license. ### # wxRuby3 wxWidgets interface director ### module WXRuby3 class Director class Clipboard < Director include Typemap::DataFormat def setup super spec.gc_as_untracked # don't even track Clipboard objects # there is no need or support for clipboard derivatives # not least because wxRuby only ever allows a single global clipboard spec.disable_proxies spec.make_abstract 'wxClipboard' # After a data object has been set to the clipboard using set_data, it # becomes owned by the clipboard and shouldn't be freed spec.disown 'wxDataObject* data' spec.add_extend_code 'wxClipboard', <<~__HEREDOC // Provide access to the global clipboard; same clipboard must be used // between calls to do data transfer properly. static VALUE get_global_clipboard() { return SWIG_NewPointerObj(wxTheClipboard, SWIGTYPE_p_wxClipboard, 0); } __HEREDOC end end # class Clipboard end # class Director end # module WXRuby3
Version data entries
16 entries across 16 versions & 1 rubygems