Skip to content

Commit

Permalink
refactor AboutCommand
Browse files Browse the repository at this point in the history
  • Loading branch information
rdp committed Feb 16, 2010
1 parent 95d377a commit 27fc538
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions plugins/redcar/redcar.rb
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,14 @@ def execute
end
end

class About < Command
def execute
new_tab = Top::NewCommand.new.run
new_tab.document.text = "About: Redcar\nVersion: #{Redcar::VERSION}\nRuby Version: #{RUBY_VERSION}\nJruby version: #{JRUBY_VERSION}\nhttp://redcareditor.com"
class AboutCommand < Command
def execute
new_tab = Top::NewCommand.new.run
new_tab.document.text = "About: Redcar\nVersion: #{Redcar::VERSION}\n" +
"Ruby Version: #{RUBY_VERSION}\n" +
"Jruby version: #{JRUBY_VERSION}\n" +
"Redcar.environment: #{Redcar.environment}\n" +
"http://redcareditor.com"
new_tab.title= 'About'
end
end
Expand Down Expand Up @@ -634,7 +638,7 @@ def self.menus
separator
end
sub_menu "Help" do
item "About", About
item "About", AboutCommand
end
end
end
Expand Down

0 comments on commit 27fc538

Please sign in to comment.