title: Popmenu is not aligned on center of listview row
body: <p>Below is the code I am using to display popupmenu , so that it appears on the center of the row of my listview</p>
  
  <pre><code>lv.setOnItemLongClickListener(new OnItemLongClickListener() {
  
          public boolean onItemLongClick(AdapterView&lt;?&gt; arg0, View arg1,
                  final int pos, long id) {
              PopupMenu popup = new PopupMenu(context, arg1);
              if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.KITKAT) {
                  popup = new PopupMenu(context, arg1,Gravity.CENTER );
              }
              //Inflating the Popup using xml file  
              popup.getMenuInflater().inflate(R.menu.listmenu, popup.getMenu());  
              ///some code
              return true;
          }
      }); 
  </code></pre>
  
  <p>But the problem is popmenu always appears on the left side.
  When I give Gravity.RIGHT, popmenu does appear on right most side of row.
  What is going wrong with the center display??</p>