aboutsummaryrefslogtreecommitdiff
path: root/gui/widgets/editable.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gui/widgets/editable.cpp')
-rw-r--r--gui/widgets/editable.cpp15
1 files changed, 13 insertions, 2 deletions
diff --git a/gui/widgets/editable.cpp b/gui/widgets/editable.cpp
index 5e7c94b64a..2af078f9f6 100644
--- a/gui/widgets/editable.cpp
+++ b/gui/widgets/editable.cpp
@@ -200,6 +200,15 @@ bool EditableWidget::handleKeyDown(Common::KeyState state) {
}
break;
+ case Common::KEYCODE_c:
+ if (g_system->hasFeature(OSystem::kFeatureClipboardSupport) && state.flags & Common::KBD_CTRL) {
+ if (!getEditString().empty())
+ g_system->setTextInClipboard(getEditString());
+ } else {
+ defaultKeyDownHandler(state, dirty, forcecaret, handled);
+ }
+ break;
+
#ifdef MACOSX
// Let ctrl-a / ctrl-e move the caret to the start / end of the line.
//
@@ -289,7 +298,7 @@ void EditableWidget::drawCaret(bool erase) {
x += getAbsX();
y += getAbsY();
- g_gui.theme()->drawCaretClip(Common::Rect(x, y, x + 1, y + editRect.height()), getBossClipRect(), erase);
+ g_gui.theme()->drawCaret(Common::Rect(x, y, x + 1, y + editRect.height()), erase);
if (erase) {
GUI::EditableWidget::String character;
@@ -318,7 +327,9 @@ void EditableWidget::drawCaret(bool erase) {
// possible glitches due to different methods used.
width = MIN(editRect.width() - caretOffset, width);
if (width > 0) {
- g_gui.theme()->drawTextClip(Common::Rect(x, y, x + width, y + editRect.height()), getBossClipRect(), character, _state, Graphics::kTextAlignLeft, _inversion, 0, false, _font, ThemeEngine::kFontColorNormal, true, _textDrawableArea);
+ g_gui.theme()->drawText(Common::Rect(x, y, x + width, y + editRect.height()), character,
+ _state, Graphics::kTextAlignLeft, _inversion, 0, false, _font,
+ ThemeEngine::kFontColorNormal, true, _textDrawableArea);
}
}