コード例 #1
0
 public void OnSharedPreferenceChanged(ISharedPreferences sharedPreferences, string key)
 {
     if (MessageLogger.LOG_KEY == key)
     {
         myFragment.mDataPortView.Text = MessageLogger.GetAllMessages(myFragment.Activity);
     }
 }
コード例 #2
0
 public void OnClick(View v)
 {
     if (v == mSendSingleConversation)
     {
         SendMessage(1, 1);
     }
     else if (v == mSendTwoConversations)
     {
         SendMessage(2, 1);
     }
     else if (v == mSendConversationWithThreeMessages)
     {
         SendMessage(1, 3);
     }
     else if (v == mClearLogButton)
     {
         MessageLogger.Clear(Activity);
         mDataPortView.Text = MessageLogger.GetAllMessages(Activity);
     }
 }
コード例 #3
0
 public override void OnResume()
 {
     base.OnResume();
     mDataPortView.Text = MessageLogger.GetAllMessages(Activity);
     MessageLogger.GetPrefs(Activity).RegisterOnSharedPreferenceChangeListener(listener);
 }