title: Error: Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@4087b120
body: <p>I am trying to make menus button for video recording start and stop:</p>
  
  <pre><code>public void vid_Recorder() {
      try {
          mRecorder.setVideoSource(MediaRecorder.VideoSource.DEFAULT);
          mRecorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);;
          mRecorder.setVideoEncoder(MediaRecorder.VideoEncoder.MPEG_4_SP);
          mRecorder.setOutputFile("/mnt/sdcard/recorder.3gpp");
          mRecorder.prepare();
          mRecorder.start();
      } catch(Exception e) {
          e.printStackTrace();
      }
  }
  </code></pre>
  
  <p>Here I had created the menu:</p>
  
  <pre><code>@Override
  public boolean onCreateOptionsMenu(Menu menu)
  {
      MenuInflater menuInflater = getMenuInflater();
      menuInflater.inflate(R.menu.menu,menu);
      return super.onCreateOptionsMenu(menu);
  }
  
  public boolean onOptionItemSelected(MenuItem Item)
  {
      switch(Item.getItemId()) {
          case R.id.menu_Start:
          {
              Toast.makeText(getApplicationContext(), "Started Recording",
                             Toast.LENGTH_LONG).show();
              vid_Recorder();
              System.out.println("Get Started");
          }
          case R.id.menu_Stop:
          {
              mRecorder.stop();
          }
      }
  
      return onOptionItemSelected(Item);
  }
  </code></pre>
  
  <p>But am not even getting that <code>system.out.println</code> statement in logcat instead of that I am getting:</p>
  
  <blockquote>
    <p>Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@406f05e8</p>
  </blockquote>