diff options
author | Andreas Kling <kling@serenityos.org> | 2020-02-25 14:49:47 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-02-25 14:52:35 +0100 |
commit | ceec1a7d38d4c8941dbf537b85bd50f0030ffbec (patch) | |
tree | 2b137c37ae0f331bb3626583a619a3175ef614d4 /Libraries/LibVT | |
parent | 9c6f7d3e7d2252ad2d51f2c7c7379cab867fa477 (diff) | |
download | serenity-ceec1a7d38d4c8941dbf537b85bd50f0030ffbec.zip |
AK: Make Vector use size_t for its size and capacity
Diffstat (limited to 'Libraries/LibVT')
-rw-r--r-- | Libraries/LibVT/Terminal.cpp | 4 | ||||
-rw-r--r-- | Libraries/LibVT/Terminal.h | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/Libraries/LibVT/Terminal.cpp b/Libraries/LibVT/Terminal.cpp index 05dc2e5959..23406aac6f 100644 --- a/Libraries/LibVT/Terminal.cpp +++ b/Libraries/LibVT/Terminal.cpp @@ -961,12 +961,12 @@ void Terminal::unimplemented_escape() builder.appendf("((Unimplemented escape: %c", m_final); if (!m_parameters.is_empty()) { builder.append(" parameters:"); - for (int i = 0; i < m_parameters.size(); ++i) + for (size_t i = 0; i < m_parameters.size(); ++i) builder.append((char)m_parameters[i]); } if (!m_intermediates.is_empty()) { builder.append(" intermediates:"); - for (int i = 0; i < m_intermediates.size(); ++i) + for (size_t i = 0; i < m_intermediates.size(); ++i) builder.append((char)m_intermediates[i]); } builder.append("))"); diff --git a/Libraries/LibVT/Terminal.h b/Libraries/LibVT/Terminal.h index 26e65749b1..8c7bc7a25b 100644 --- a/Libraries/LibVT/Terminal.h +++ b/Libraries/LibVT/Terminal.h @@ -128,7 +128,7 @@ public: return m_lines[index]; } - int max_history_size() const { return 500; } + size_t max_history_size() const { return 500; } const NonnullOwnPtrVector<Line>& history() const { return m_history; } void inject_string(const StringView&); @@ -184,8 +184,8 @@ private: NonnullOwnPtrVector<Line> m_history; NonnullOwnPtrVector<Line> m_lines; - int m_scroll_region_top { 0 }; - int m_scroll_region_bottom { 0 }; + size_t m_scroll_region_top { 0 }; + size_t m_scroll_region_bottom { 0 }; u16 m_columns { 1 }; u16 m_rows { 1 }; |