title: Android while working in app page, after received push notification in mobile, need to update some text
body: <p>I have receiving <code>GCM push notification</code> message in my mobile successfully. But, I want to make some text update in my app working page.</p>
  
  <p>While receiving push notification, app page automatically need to change text like push notification received and show to any text view, in working page.</p>
  
  <p>Already referred: <a href="https://stackoverflow.com/questions/27240817/updating-the-ui-upon-receiving-an-android-push-notification">Updating the UI upon receiving an android push notification</a></p>
  
  <p>For <code>push notification</code> am using this class to <code>receive notification</code>:</p>
  
  <pre><code>public class GCMBroadcastReceiver extends WakefulBroadcastReceiver
  {
      @Override
      public void onReceive(Context context, Intent intent) {
  
      }
  }
  </code></pre>
  
  <hr>
  
  <p>For MainPage Push notif text showing Activity Page Code:</p>
  
  <pre><code>public void onResume(){
      super.onResume() ;
      Log.v("tag","onResume working...")      ;
      broadcast = new BroadcastReceiver() {
      @Override
          public void onReceive(Context context, Intent intent) {
              Toast.makeText(getApplicationContext(), "Receiver...", 1).show();   
          }
      };
      LocalBroadcastManager.getInstance(this).registerReceiver(broadcast,new IntentFilter("com.google.android.c2dm.intent.REGISTRATION"));
  }
  
  @Override
  protected void onPause() {
      super.onPause();
      LocalBroadcastManager.getInstance(this).unregisterReceiver(broadcast);
  }
  </code></pre>
  
  <p>My above code: exactly don't know the mistake in code..</p>