1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-23 01:44:22 +00:00

Cleaned up some caret code in TextEditor.

This commit is contained in:
jules 2015-09-24 16:32:38 -07:00
parent cd7efdf8b4
commit 7edb1b5614
2 changed files with 7 additions and 1 deletions

View file

@ -1082,6 +1082,11 @@ void TextEditor::colourChanged()
}
void TextEditor::lookAndFeelChanged()
{
recreateCaret();
}
void TextEditor::recreateCaret()
{
if (isCaretVisible())
{
@ -2128,7 +2133,7 @@ void TextEditor::handleCommandMessage (const int commandId)
void TextEditor::enablementChanged()
{
setCaretVisible (isCaretVisible());
recreateCaret();
repaint();
}

View file

@ -712,6 +712,7 @@ private:
void moveCaret (int newCaretPos);
void moveCaretTo (int newPosition, bool isSelecting);
void recreateCaret();
void handleCommandMessage (int) override;
void coalesceSimilarSections();
void splitSection (int sectionIndex, int charToSplitAt);