title: inflate sherlock action bar menu from xml and for each fragment
body: <p>I'm creating action bar menu in my main activity:</p>
  
  <pre><code>public boolean onCreateOptionsMenu(Menu menu) {
      // Used to put dark icons on light action bar
      SubMenu sub = menu.addSubMenu(null);
      sub.add(0, R.style.Theme_Sherlock, 0, "Default");
      sub.add(0, R.style.Theme_Sherlock_Light, 0, "Light");
      sub.add(0, R.style.Theme_Sherlock_Light_DarkActionBar, 0,
              "Light (Dark Action Bar)");
  
      MenuItem ShareButton = sub.getItem();
      ShareButton.setIcon(R.drawable.ic_action_overflow);
      ShareButton.setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS
              | MenuItem.SHOW_AS_ACTION_WITH_TEXT);
  
      return true;
  
  }
  </code></pre>
  
  <p>And then in my fragment activity, I try to change menu for second fragment:</p>
  
  <pre><code>first i do this:
   @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setHasOptionsMenu(true);
      }
  </code></pre>
  
  <p>And I do this:</p>
  
  <pre><code>@Override
      public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
          // TODO Auto-generated method stub
          //final MenuInflater inflater2 = getMenuInflater();
          //inflater.inflate(R.menu.historymenu, menu);
          Log.v("Some Log", "I'm in on Create Options Menu");
  
          SubMenu sub = menu.addSubMenu(null);
          sub.add(0, R.style.Theme_Sherlock, 0, "HistoryCheck");
  
  
          MenuItem ShareButton = sub.getItem();
          ShareButton.setIcon(R.drawable.ic_action_overflow);
          ShareButton.setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS
                  | MenuItem.SHOW_AS_ACTION_WITH_TEXT);
  
          super.onCreateOptionsMenu(menu, inflater);
      }
  </code></pre>
  
  <p>As you can see, I'd love to inflate menu from .xml for each fragment and main activity but for some reason inflation does nothing. </p>
  
  <p>With code to add new submenu, I get 2 menus when I switch to second tab/fragment, and I'd love to change existing menu, not to add additional one. </p>
  
  <p>Please help me to change correct line. </p>
  
  <p>Tnx. </p>