diff --git a/res/menu/call_log_options.xml b/res/menu/call_log_options.xml
index c41f9da..d393a9e 100644
--- a/res/menu/call_log_options.xml
+++ b/res/menu/call_log_options.xml
@@ -16,20 +16,44 @@
 <menu xmlns:android="http://schemas.android.com/apk/res/android">
 
     <item
-        android:id="@+id/show_voicemails_only"
-        android:title="@string/menu_show_voicemails_only"
-        android:showAsAction="withText"
-        android:orderInCategory="1" />
+            android:id="@+id/show_all_calls"
+            android:title="@string/menu_show_all_calls"
+            android:icon="@drawable/quickcon_background_texture"
+            android:showAsAction="ifRoom"
+            android:orderInCategory="1"/>
 
     <item
-        android:id="@+id/show_all_calls"
-        android:title="@string/menu_show_all_calls"
-        android:showAsAction="withText"
-        android:orderInCategory="1" />
+            android:id="@+id/show_voicemails_only"
+            android:title="@string/menu_show_voicemails_only"
+            android:icon="@drawable/ic_call_voicemail_holo_dark"
+            android:showAsAction="ifRoom"
+            android:orderInCategory="1"/>
 
     <item
-        android:id="@+id/delete_all"
-        android:title="@string/recentCalls_deleteAll"
-        android:showAsAction="withText"
-        android:orderInCategory="1" />
+            android:id="@+id/show_missed_only"
+            android:title="@string/menu_show_missed_only"
+            android:icon="@drawable/ic_call_missed_holo_dark"
+            android:showAsAction="ifRoom"
+            android:orderInCategory="1"/>
+
+    <item
+            android:id="@+id/show_outgoing_only"
+            android:title="@string/menu_show_outgoing_only"
+            android:icon="@drawable/ic_call_outgoing_holo_dark"
+            android:showAsAction="ifRoom"
+            android:orderInCategory="1"/>
+
+    <item
+            android:id="@+id/show_incoming_only"
+            android:title="@string/menu_show_incoming_only"
+            android:icon="@drawable/ic_call_incoming_holo_dark"
+            android:showAsAction="ifRoom"
+            android:orderInCategory="1"/>
+
+
+    <item
+            android:id="@+id/delete_all"
+            android:title="@string/recentCalls_deleteAll"
+            android:showAsAction="withText"
+            android:orderInCategory="1"/>
 </menu>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index a924648..3b5ccd1 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -1651,6 +1651,15 @@
     <!-- The "file name" displayed for vCards received directly via NFC [CHAR LIMIT=16] -->
     <string name="nfc_vcard_file_name">Contact received over NFC</string>
 
+    <!-- Menu item used to show only outgoing in the call log. [CHAR LIMIT=30] -->
+    <string name="menu_show_outgoing_only">Show outgoing only</string>
+
+    <!-- Menu item used to show only incoming in the call log. [CHAR LIMIT=30] -->
+    <string name="menu_show_incoming_only">Show incoming only</string>
+
+    <!-- Menu item used to show only missed in the call log. [CHAR LIMIT=30] -->
+    <string name="menu_show_missed_only">Show missed only</string>
+
     <!-- Menu item used to show only voicemails in the call log. [CHAR LIMIT=30] -->
     <string name="menu_show_voicemails_only">Show voicemails only</string>
 
diff --git a/src/com/android/contacts/activities/DialtactsActivity.java b/src/com/android/contacts/activities/DialtactsActivity.java
index b71f15a..2e35213 100644
--- a/src/com/android/contacts/activities/DialtactsActivity.java
+++ b/src/com/android/contacts/activities/DialtactsActivity.java
@@ -1017,7 +1017,7 @@
             // When there is a permanent menu key, there is no overflow icon on the right of
             // the action bar which would force the search menu item (if it is visible) to the
             // left.  This is the purpose of showing the emptyRightMenuItem.
-            emptyRightMenuItem.setVisible(ViewConfiguration.get(this).hasPermanentMenuKey());
+            emptyRightMenuItem.setVisible(false);
         } else {
             // This is when the user is looking at the dialer pad.  In this case, the real
             // ActionBar is hidden and fake menu items are shown.
@@ -1038,11 +1038,11 @@
         final MenuItem emptyRightMenuItem = menu.findItem(R.id.empty_right_menu_item);
 
         // prepare the menu items
-        searchMenuItem.setVisible(true);
+        searchMenuItem.setVisible(false);
         filterOptionMenuItem.setVisible(false);
         addContactOptionMenuItem.setVisible(false);
         callSettingsMenuItem.setVisible(true);
-        emptyRightMenuItem.setVisible(ViewConfiguration.get(this).hasPermanentMenuKey());
+        emptyRightMenuItem.setVisible(false);
     }
 
     private void prepareOptionsMenuForFavoritesTab(Menu menu) {
diff --git a/src/com/android/contacts/calllog/CallLogFragment.java b/src/com/android/contacts/calllog/CallLogFragment.java
index f04a2f3..739cf35 100644
--- a/src/com/android/contacts/calllog/CallLogFragment.java
+++ b/src/com/android/contacts/calllog/CallLogFragment.java
@@ -331,10 +331,7 @@
         // menu items are ready if the first item is non-null.
         if (itemDeleteAll != null) {
             itemDeleteAll.setEnabled(mAdapter != null && !mAdapter.isEmpty());
-            menu.findItem(R.id.show_voicemails_only).setVisible(
-                    mVoicemailSourcesAvailable && !mShowingVoicemailOnly);
-            menu.findItem(R.id.show_all_calls).setVisible(
-                    mVoicemailSourcesAvailable && mShowingVoicemailOnly);
+            menu.findItem(R.id.show_voicemails_only).setVisible(mVoicemailSourcesAvailable);
         }
     }
 
@@ -345,6 +342,21 @@
                 ClearCallLogDialog.show(getFragmentManager());
                 return true;
 
+            case R.id.show_outgoing_only:
+                mCallLogQueryHandler.fetchOutgoing();
+
+                return true;
+
+            case R.id.show_incoming_only:
+                mCallLogQueryHandler.fetchIncoming();
+
+                return true;
+
+            case R.id.show_missed_only:
+                mCallLogQueryHandler.fetchMissed();
+
+                return true;
+
             case R.id.show_voicemails_only:
                 mCallLogQueryHandler.fetchVoicemailOnly();
                 mShowingVoicemailOnly = true;
diff --git a/src/com/android/contacts/calllog/CallLogQueryHandler.java b/src/com/android/contacts/calllog/CallLogQueryHandler.java
index ba604cd..3ef2f7d 100644
--- a/src/com/android/contacts/calllog/CallLogQueryHandler.java
+++ b/src/com/android/contacts/calllog/CallLogQueryHandler.java
@@ -29,6 +29,7 @@
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
+import android.provider.CallLog;
 import android.provider.CallLog.Calls;
 import android.provider.VoicemailContract.Status;
 import android.util.Log;
@@ -159,8 +160,8 @@
     public void fetchAllCalls() {
         cancelFetch();
         int requestId = newCallsRequest();
-        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, false /*voicemailOnly*/);
-        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, false /*voicemailOnly*/);
+        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, -1 /*callType*/);
+        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, -1 /*callType*/);
     }
 
     /**
@@ -171,10 +172,30 @@
     public void fetchVoicemailOnly() {
         cancelFetch();
         int requestId = newCallsRequest();
-        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, true /*voicemailOnly*/);
-        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, true /*voicemailOnly*/);
+        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, Calls.VOICEMAIL_TYPE);
+        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, Calls.VOICEMAIL_TYPE);
     }
 
+    public void fetchOutgoing() {
+        cancelFetch();
+        int requestId = newCallsRequest();
+        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, Calls.OUTGOING_TYPE);
+        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, Calls.OUTGOING_TYPE);
+    }
+
+    public void fetchIncoming() {
+        cancelFetch();
+        int requestId = newCallsRequest();
+        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, Calls.INCOMING_TYPE);
+        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, Calls.INCOMING_TYPE);
+    }
+
+    public void fetchMissed() {
+        cancelFetch();
+        int requestId = newCallsRequest();
+        fetchCalls(QUERY_NEW_CALLS_TOKEN, requestId, true /*isNew*/, Calls.MISSED_TYPE);
+        fetchCalls(QUERY_OLD_CALLS_TOKEN, requestId, false /*isNew*/, Calls.MISSED_TYPE);
+    }
 
     public void fetchVoicemailStatus() {
         startQuery(QUERY_VOICEMAIL_STATUS_TOKEN, null, Status.CONTENT_URI,
@@ -182,7 +203,7 @@
     }
 
     /** Fetches the list of calls in the call log, either the new one or the old ones. */
-    private void fetchCalls(int token, int requestId, boolean isNew, boolean voicemailOnly) {
+    private void fetchCalls(int token, int requestId, boolean isNew, int callType) {
         // We need to check for NULL explicitly otherwise entries with where READ is NULL
         // may not match either the query or its negation.
         // We consider the calls that are not yet consumed (i.e. IS_READ = 0) as "new".
@@ -194,10 +215,10 @@
             // Negate the query.
             selection = String.format("NOT (%s)", selection);
         }
-        if (voicemailOnly) {
+        if (callType > 0) {
             // Add a clause to fetch only items of type voicemail.
             selection = String.format("(%s) AND (%s = ?)", selection, Calls.TYPE);
-            selectionArgs.add(Integer.toString(Calls.VOICEMAIL_TYPE));
+            selectionArgs.add(Integer.toString(callType));
         }
         startQuery(token, requestId, Calls.CONTENT_URI_WITH_VOICEMAIL,
                 CallLogQuery._PROJECTION, selection, selectionArgs.toArray(EMPTY_STRING_ARRAY),
