Changeset View
Changeset View
Standalone View
Standalone View
source/gui/CInput.h
/* Copyright (C) 2017 Wildfire Games. | /* Copyright (C) 2018 Wildfire Games. | ||||
* This file is part of 0 A.D. | * This file is part of 0 A.D. | ||||
* | * | ||||
* 0 A.D. is free software: you can redistribute it and/or modify | * 0 A.D. is free software: you can redistribute it and/or modify | ||||
* it under the terms of the GNU General Public License as published by | * it under the terms of the GNU General Public License as published by | ||||
* the Free Software Foundation, either version 2 of the License, or | * the Free Software Foundation, either version 2 of the License, or | ||||
* (at your option) any later version. | * (at your option) any later version. | ||||
* | * | ||||
* 0 A.D. is distributed in the hope that it will be useful, | * 0 A.D. is distributed in the hope that it will be useful, | ||||
▲ Show 20 Lines • Show All 111 Lines • ▼ Show 20 Lines | protected: | ||||
/// Called every time the auto-scrolling should be checked. | /// Called every time the auto-scrolling should be checked. | ||||
void UpdateAutoScroll(); | void UpdateAutoScroll(); | ||||
/// Clear composed IME input when supported (SDL2 only). | /// Clear composed IME input when supported (SDL2 only). | ||||
void ClearComposedText(); | void ClearComposedText(); | ||||
/// Updates the buffer (cursor) position exposed to JS. | /// Updates the buffer (cursor) position exposed to JS. | ||||
void UpdateBufferPositionSetting(); | void UpdateBufferPositionSetting(); | ||||
// Stop the SDL text input when field is destroyed, so a next field doesn't get old textEvents. | |||||
void Destroy(); | |||||
vladislavbelov: Who is calling this? | |||||
bbAuthorUnsubmitted Not Done Inline ActionsCalled from the CGUI destroy function. bb: Called from the CGUI destroy function. | |||||
protected: | protected: | ||||
/// Cursor position | /// Cursor position | ||||
Not Done Inline ActionsWe use upper camel case with the m_* prefix. It should be m_Focus. vladislavbelov: We use upper camel case with the `m_*` prefix. It should be `m_Focus`. | |||||
int m_iBufferPos; | int m_iBufferPos; | ||||
/// Cursor position we started to select from. (-1 if not selecting) | /// Cursor position we started to select from. (-1 if not selecting) | ||||
/// (NB: Can be larger than m_iBufferPos if selecting from back to front.) | /// (NB: Can be larger than m_iBufferPos if selecting from back to front.) | ||||
int m_iBufferPos_Tail; | int m_iBufferPos_Tail; | ||||
/// If we're composing text with an IME | /// If we're composing text with an IME | ||||
bool m_ComposingText; | bool m_ComposingText; | ||||
/// The length and position of the current IME composition | /// The length and position of the current IME composition | ||||
▲ Show 20 Lines • Show All 55 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator
Who is calling this?