Sha256: 8c752a7e45330154036575714d47e75da593c038e70c554eeae3abdf2ae63f21
Contents?: true
Size: 409 Bytes
Versions: 2
Compression:
Stored size: 409 Bytes
Contents
# frozen_string_literal: true class Shoes module Common module State DISABLED_STATE = "disabled" def after_initialize(*_) super update_from_state end def state=(value) style(state: value) end def enabled? state.to_s != DISABLED_STATE end def update_from_state @gui.enabled(enabled?) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
shoes-core-4.0.0.pre12 | lib/shoes/common/state.rb |
shoes-core-4.0.0.pre11 | lib/shoes/common/state.rb |