Sha256: bfca07f97cc5e6d6643b346a4d4f81345666765ad0991d15560f254f59f9befd
Contents?: true
Size: 1.05 KB
Versions: 3
Compression:
Stored size: 1.05 KB
Contents
require 'clevic/delegate' module Clevic class Delegate def initialize( field ) @field = field @message_receivers = Set.new end # FIXME this must actually show a message, and # the Qt code must use it too def show_message( msg, &block ) if block_given? @message_receivers << block else @message_receivers.each do |receiver| receiver.call( msg ) end end end # workaround for broken JTable editing starts def needs_pre_selection? false end # Return something useful if this should use the default GUI framework # mechanism for table editing. Default is false, so native framework # won't be used. For Java/Swing, this would return the a class object # indicating the type of data, eg java.lang.Boolean, or java.lang.String # or something from JTable.setDefaultEditor def native false end def inspect "<#{self.class.name} native=#{native} needs_pre_selection=#{needs_pre_selection?}>" end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
clevic-0.13.0.b9 | lib/clevic/swing/delegate.rb |
clevic-0.13.0.b6 | lib/clevic/swing/delegate.rb |
clevic-0.13.0.b5 | lib/clevic/swing/delegate.rb |