Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2acbf6ce authored by Philip P. Moltmann's avatar Philip P. Moltmann Committed by Android (Google) Code Review
Browse files

Merge "Don't attempt to create context menu for 'add printer' entry"

parents 8d6427d3 ae2b732d
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -285,6 +285,11 @@ public final class SelectPrinterActivity extends Activity implements
            final int position = ((AdapterContextMenuInfo) menuInfo).position;
            PrinterInfo printer = (PrinterInfo) mListView.getAdapter().getItem(position);

            // Printer is null if this is a context menu for the "add printer" entry
            if (printer == null) {
                return;
            }

            menu.setHeaderTitle(printer.getName());

            // Add the select menu item if applicable.