mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Remove m_bReadOnly from CTextLogger
User can't modify the log text, it can only be modified through code.
This commit is contained in:
parent
33aebfb89d
commit
f52bfb139e
@ -126,8 +126,6 @@ public:
|
||||
int GetTotalLines() const { return (int)m_Lines.size(); }
|
||||
bool IsOverwrite() const { return m_Overwrite; }
|
||||
|
||||
void SetReadOnly(bool aValue);
|
||||
bool IsReadOnly() const { return m_bReadOnly; }
|
||||
bool IsCursorPositionChanged() const { return m_bCursorPositionChanged; }
|
||||
|
||||
Coordinates GetCursorPosition() const { return GetActualCursorCoordinates(); }
|
||||
@ -211,7 +209,6 @@ private:
|
||||
|
||||
int m_nTabSize;
|
||||
bool m_Overwrite;
|
||||
bool m_bReadOnly;
|
||||
bool m_bWithinRender;
|
||||
bool m_bScrollToCursor;
|
||||
float m_flTextStart; // position (in pixels) where a code line starts relative to the left of the TextEditor.
|
||||
|
13
r5dev/thirdparty/imgui/src/imgui_logger.cpp
vendored
13
r5dev/thirdparty/imgui/src/imgui_logger.cpp
vendored
@ -25,7 +25,6 @@ CTextLogger::CTextLogger()
|
||||
: m_flLineSpacing(1.0f)
|
||||
, m_nTabSize(4)
|
||||
, m_Overwrite(false)
|
||||
, m_bReadOnly(false)
|
||||
, m_bWithinRender(false)
|
||||
, m_bScrollToCursor(false)
|
||||
, m_flTextStart(0.f)
|
||||
@ -198,7 +197,6 @@ void CTextLogger::Advance(Coordinates & aCoordinates) const
|
||||
void CTextLogger::DeleteRange(const Coordinates & aStart, const Coordinates & aEnd)
|
||||
{
|
||||
assert(aEnd >= aStart);
|
||||
assert(!m_bReadOnly);
|
||||
|
||||
//printf("D(%d.%d)-(%d.%d)\n", aStart.mLine, aStart.mColumn, aEnd.mLine, aEnd.mColumn);
|
||||
|
||||
@ -235,8 +233,6 @@ void CTextLogger::DeleteRange(const Coordinates & aStart, const Coordinates & aE
|
||||
|
||||
int CTextLogger::InsertTextAt(Coordinates& /* inout */ aWhere, const char * aValue, ImVec4 aColor)
|
||||
{
|
||||
assert(!m_bReadOnly);
|
||||
|
||||
int cindex = GetCharacterIndex(aWhere);
|
||||
int totalLines = 0;
|
||||
|
||||
@ -532,7 +528,6 @@ void CTextLogger::RemoveLine(int aStart, int aEnd)
|
||||
{
|
||||
m_Mutex.lock();
|
||||
|
||||
assert(!m_bReadOnly);
|
||||
assert(aEnd >= aStart);
|
||||
assert(m_Lines.size() > (size_t)(aEnd - aStart));
|
||||
|
||||
@ -546,7 +541,6 @@ void CTextLogger::RemoveLine(int aIndex)
|
||||
{
|
||||
m_Mutex.lock();
|
||||
|
||||
assert(!m_bReadOnly);
|
||||
assert(m_Lines.size() > 1);
|
||||
|
||||
m_Lines.erase(m_Lines.begin() + aIndex);
|
||||
@ -557,8 +551,6 @@ void CTextLogger::RemoveLine(int aIndex)
|
||||
|
||||
CTextLogger::Line& CTextLogger::InsertLine(int aIndex)
|
||||
{
|
||||
assert(!m_bReadOnly);
|
||||
|
||||
auto& result = *m_Lines.insert(m_Lines.begin() + aIndex, Line());
|
||||
return result;
|
||||
}
|
||||
@ -964,11 +956,6 @@ void CTextLogger::SetTextLines(const std::vector<CConLog>& aLines)
|
||||
}
|
||||
}
|
||||
|
||||
void CTextLogger::SetReadOnly(bool aValue)
|
||||
{
|
||||
m_bReadOnly = aValue;
|
||||
}
|
||||
|
||||
void CTextLogger::SetCursorPosition(const Coordinates & aPosition)
|
||||
{
|
||||
if (m_State.m_CursorPosition != aPosition)
|
||||
|
Loading…
x
Reference in New Issue
Block a user