Skip to content

Commit

Permalink
closes #193 Fix ask on QT 4.6.2
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanmelt committed Sep 18, 2015
1 parent 9c847a4 commit 3ab9bac
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions lib/cosmos/gui/utilities/script_module_gui.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,9 @@ def self.warning(parent, title, text,
end

class Qt::InputDialog
def self.getText(parent, title, label,
mode = Qt::LineEdit::Normal,
text = '', ok = 0, flags = 0,
inputMethodHints = Qt::ImhNone)
def self.getText(*args)
Cosmos.play_wav_file(Cosmos.data_path('input.wav')) if Cosmos::System.sound
super(parent, title, label, mode, text, ok, flags, inputMethodHints)
super(*args)
end
end

Expand Down

1 comment on commit 3ab9bac

@jmthomas
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we weren't changing any of the defaults anyway (http://doc.qt.io/qt-4.8/qinputdialog.html#getText) then I think this is fine.

Please sign in to comment.