class Plugin::ChangeAccount::AccountControl

Constants

COL_ICON
COL_NAME
COL_SCREEN_NAME
COL_SERVICE

Public Instance Methods

column_schemer() click to toggle source
# File core/plugin/change_account/account_control.rb, line 9
def column_schemer
  [{:kind => :pixbuf, :type => GdkPixbuf::Pixbuf, :label => ''},
   {:kind => :text, :type => String, :label => Plugin[:change_account]._('SN')},
   {:kind => :text, :type => String, :label => Plugin[:change_account]._('名前')},
   {:type => Object},
  ].freeze
end
force_record_create(service) click to toggle source
# File core/plugin/change_account/account_control.rb, line 17
def force_record_create(service)
  type_strict service => Service
  return if self.destroyed?
  [service.user_obj[:name], service.user_obj[:idname], service]
  iter = model.model.append
  iter[COL_ICON] = service.user_obj.icon.load_pixbuf(width: 16, height: 16) { |new_pixbuf|
    iter[COL_ICON] = new_pixbuf if not self.destroyed? }
  iter[COL_SCREEN_NAME] = service.user_obj[:idname]
  iter[COL_NAME] = service.user_obj[:name]
  iter[COL_SERVICE] = service
  on_created(iter)
end
on_deleted(iter) click to toggle source
# File core/plugin/change_account/account_control.rb, line 30
def on_deleted(iter)
  Service.destroy(iter[COL_SERVICE]) end
popup_input_window(defaults = []) click to toggle source