lazily initialize emoji drawer

Saves a good amount of inflation time in onCreate for new conversations.

Closes #2585
Closes #2636

// FREEBIE
This commit is contained in:
Jake McGinty
2015-03-09 15:13:13 -07:00
committed by Moxie Marlinspike
parent a625727853
commit 9f804047f5
3 changed files with 31 additions and 16 deletions

View File

@@ -122,11 +122,10 @@
</LinearLayout>
</RelativeLayout>
<org.thoughtcrime.securesms.components.EmojiDrawer
android:id="@+id/emoji_drawer"
android:visibility="gone"
android:layout_weight="1.1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"/>
<ViewStub android:id="@+id/emoji_drawer_stub"
android:inflatedId="@+id/emoji_drawer"
android:layout="@layout/emoji_drawer_stub"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<org.thoughtcrime.securesms.components.EmojiDrawer
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1.1" />