summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinWX/NetWindow.cpp
diff options
context:
space:
mode:
authorshuffle2 <godisgovernment@gmail.com>2014-07-14 01:56:09 -0700
committershuffle2 <godisgovernment@gmail.com>2014-07-14 01:56:09 -0700
commit3ac4e9f171b116d4b09990058c18741598bb2ef8 (patch)
tree65e6a27d3952da5d8df5bcac80374fadf925724e /Source/Core/DolphinWX/NetWindow.cpp
parent0c6eeaff05bd4975fd33880af1ddf45fc09ca763 (diff)
parentd931637d63f361b0523f415ea90c6bdde1b708bb (diff)
Merge pull request #608 from lioncash/compat
DolphinWX: Remove the use of some wx 1.0 compatibility function calls.
Diffstat (limited to 'Source/Core/DolphinWX/NetWindow.cpp')
-rw-r--r--Source/Core/DolphinWX/NetWindow.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/Core/DolphinWX/NetWindow.cpp b/Source/Core/DolphinWX/NetWindow.cpp
index 391ce0ff9c..a3d685b1f8 100644
--- a/Source/Core/DolphinWX/NetWindow.cpp
+++ b/Source/Core/DolphinWX/NetWindow.cpp
@@ -428,14 +428,15 @@ NetPlayDiag::~NetPlayDiag()
void NetPlayDiag::OnChat(wxCommandEvent&)
{
- wxString s = m_chat_msg_text->GetValue();
+ wxString text = m_chat_msg_text->GetValue();
- if (s.Length())
+ if (!text.empty())
{
- if (s.Length() > 2000)
- s.erase(2000);
- netplay_client->SendChatMessage(WxStrToStr(s));
- m_chat_text->AppendText(s.Prepend(" >> ").Append('\n'));
+ if (text.length() > 2000)
+ text.erase(2000);
+
+ netplay_client->SendChatMessage(WxStrToStr(text));
+ m_chat_text->AppendText(text.Prepend(" >> ").Append('\n'));
m_chat_msg_text->Clear();
}
}
@@ -557,11 +558,11 @@ void NetPlayDiag::OnThread(wxCommandEvent& event)
// remove ping from selection string, in case it has changed
selection.erase(selection.find_last_of("|") + 1);
- if (selection.Length() > 0)
+ if (!selection.empty())
{
for (unsigned int i = 0; i < m_player_lbox->GetCount(); ++i)
{
- if (selection == m_player_lbox->GetString(i).Mid(0, selection.Length()))
+ if (selection == m_player_lbox->GetString(i).Mid(0, selection.length()))
{
m_player_lbox->SetSelection(i);
break;