"insert parameter" and "user parameter" buttons now work.

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@271 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-04-21 01:10:32 +00:00
parent fef99c78e3
commit 5327520646
10 changed files with 102 additions and 42 deletions
+4
View File
@@ -161,6 +161,10 @@ void DataEditor::onCommand(int id) {
}
}
void DataEditor::insert(const String& text, const String& action_name) {
if (current_editor) current_editor->insert(text, action_name);
}
// ----------------------------------------------------------------------------- : Mouse events
void DataEditor::onLeftDown(wxMouseEvent& ev) {
+5
View File
@@ -70,6 +70,11 @@ class DataEditor : public CardViewer {
*/
bool search(FindInfo& find, bool from_start);
// --------------------------------------------------- : Selection in editor
/// Insert 'text' into the current editor, using an action with the given name
void insert(const String& text, const String& action_name);
// --------------------------------------------------- : ValueViewers
protected:
+3
View File
@@ -91,6 +91,9 @@ void TextCtrl::onChangeSet() {
} else {
setValue(nullptr);
}
// select the one and only editor
current_viewer = viewers.front().get();
current_editor = current_viewer->getEditor();
}
void TextCtrl::onInit() {