Browse Source

tags/2021-05-28
jules 18 years ago
parent
commit
5b1f5d6bfb
2 changed files with 4 additions and 4 deletions
  1. +1
    -1
      src/juce_appframework/gui/components/controls/juce_TextEditor.cpp
  2. +3
    -3
      src/juce_appframework/gui/components/keyboard/juce_KeyPress.h

+ 1
- 1
src/juce_appframework/gui/components/controls/juce_TextEditor.cpp View File

@@ -1883,7 +1883,7 @@ bool TextEditor::keyPressed (const KeyPress& key)
moveCursorTo (getTotalNumChars(), false);
moveCursorTo (0, true);
}
else if (key.isKeyCode (KeyPress::returnKey))
else if (key == KeyPress::returnKey)
{
if (! isReadOnly())
{


+ 3
- 3
src/juce_appframework/gui/components/keyboard/juce_KeyPress.h View File

@@ -57,8 +57,8 @@ public:
/** Creates a KeyPress for a key and some modifiers.
e.g.
CTRL+C would be: KeyPress ('c', Modifiers::ctrlModifier)
SHIFT+Escape would be: KeyPress (KeyPress::escapeKey, Modifiers::shiftModifier)
CTRL+C would be: KeyPress ('c', ModifierKeys::ctrlModifier)
SHIFT+Escape would be: KeyPress (KeyPress::escapeKey, ModifierKeys::shiftModifier)
@param keyCode a code that represents the key - this value must be
one of special constants listed in this class, or an
@@ -110,7 +110,7 @@ public:
/** Returns the key modifiers.
@see Modifiers
@see ModifierKeys
*/
const ModifierKeys getModifiers() const throw() { return mods; }


Loading…
Cancel
Save