- Two of the most useful shortcuts utilize the Fn (function) keys. It is therefore recommended that you enable the "Use all F1, F2, etc. keys as standard function keys" option [System Preferences > Keyboard].
- Be sure to enable the Mac OS X 10.5+ keymap in Android Studio [Preferences > Keymap].
- A fairly complete shortcut list can be found here.
Instantly share code, notes, and snippets.
- Dubai
ismkhanh
/ android_studio_shortcuts.md
Created
October 13, 2017 14:07
— forked from stkent/android_studio_shortcuts.md
Android Studio Shortcuts (Mac)
ismkhanh
/ linkedlist_add_item_at_last.md
Last active
November 9, 2017 11:30
Adding an item to LinkedList
/**
* Adds elements at the end of the list
*
* @param value to be added
*/
public void addItem(int value) {
Node newNode = new Node(value);
ismkhanh
/ linkedlist_delete_item.md
Last active
November 9, 2017 11:30
Deleting item from LinkedList
/**
* Deletes the value, if present, from the list
*
* @param value to be deleted
*/
public void deleteItem(int value) {
if (head != null) { //if head is null no items to delete
ismkhanh
/ linkedlist_print_all_elements.md
Created
November 9, 2017 11:28
Print all the elements of LinkedList
/**
* Print the values of the list
*/
public void print() {
System.out.print("LinkedList: [");
Node current = head;
ismkhanh
/ navigation_dependencies
Created
July 22, 2018 07:48
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| implementation 'android.arch.navigation:navigation-fragment:1.0.0-alpha01 | |
| implementation 'android.arch.navigation:navigation-ui:1.0.0-alpha01' |
ismkhanh
/ navigation_main_activity
Last active
July 22, 2018 08:05
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
| xmlns:app="http://schemas.android.com/apk/res-auto" | |
| xmlns:tools="http://schemas.android.com/tools" | |
| android:layout_width="match_parent" | |
| android:layout_height="match_parent" | |
| android:orientation="vertical" | |
| tools:context=".MainActivity"> | |
| <fragment |
ismkhanh
/ navigation_first_fragment
Created
July 22, 2018 08:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
| xmlns:tools="http://schemas.android.com/tools" | |
| android:layout_width="match_parent" | |
| android:layout_height="match_parent" | |
| android:gravity="center" | |
| android:orientation="vertical" | |
| tools:context=".FirstFragment"> | |
| <TextView |
ismkhanh
/ navigation_first_fragment_added
Created
July 22, 2018 09:45
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <navigation xmlns:android="http://schemas.android.com/apk/res/android" | |
| xmlns:app="http://schemas.android.com/apk/res-auto" | |
| xmlns:tools="http://schemas.android.com/tools" | |
| android:id="@+id/mobile_navigation" | |
| app:startDestination="@id/firstFragment"> | |
| <fragment | |
| android:id="@+id/firstFragment" | |
| android:name="com.ik.navigationjetpack.FirstFragment" |
ismkhanh
/ navigation_second_fragment
Created
July 22, 2018 10:25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
| xmlns:tools="http://schemas.android.com/tools" | |
| android:layout_width="match_parent" | |
| android:layout_height="match_parent" | |
| android:orientation="vertical" | |
| tools:context=".SecondFragment" | |
| android:gravity="center"> | |
| <TextView |
ismkhanh
/ navigation_firstfragment.kt
Created
July 22, 2018 10:27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.ik.navigationjetpack | |
| import android.os.Bundle | |
| import android.support.v4.app.Fragment | |
| import android.view.LayoutInflater | |
| import android.view.View | |
| import android.view.ViewGroup | |
| import androidx.navigation.Navigation | |
| import kotlinx.android.synthetic.main.fragment_first.* |
OlderNewer