Giphy integration
// FREEBIE
BIN
res/drawable-hdpi/ic_dashboard_white_24dp.png
Normal file
After Width: | Height: | Size: 130 B |
BIN
res/drawable-hdpi/ic_gif_white_36dp.png
Normal file
After Width: | Height: | Size: 243 B |
BIN
res/drawable-hdpi/ic_view_stream_white_24dp.png
Normal file
After Width: | Height: | Size: 105 B |
BIN
res/drawable-hdpi/poweredby_giphy.png
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
res/drawable-mdpi/ic_dashboard_white_24dp.png
Normal file
After Width: | Height: | Size: 94 B |
BIN
res/drawable-mdpi/ic_gif_white_36dp.png
Normal file
After Width: | Height: | Size: 196 B |
BIN
res/drawable-mdpi/ic_view_stream_white_24dp.png
Normal file
After Width: | Height: | Size: 82 B |
BIN
res/drawable-mdpi/poweredby_giphy.png
Normal file
After Width: | Height: | Size: 2.4 KiB |
BIN
res/drawable-xhdpi/ic_dashboard_white_24dp.png
Normal file
After Width: | Height: | Size: 104 B |
BIN
res/drawable-xhdpi/ic_gif_white_36dp.png
Normal file
After Width: | Height: | Size: 213 B |
BIN
res/drawable-xhdpi/ic_view_stream_white_24dp.png
Normal file
After Width: | Height: | Size: 92 B |
BIN
res/drawable-xhdpi/poweredby_giphy.png
Normal file
After Width: | Height: | Size: 5.4 KiB |
BIN
res/drawable-xxhdpi/ic_dashboard_white_24dp.png
Normal file
After Width: | Height: | Size: 109 B |
BIN
res/drawable-xxhdpi/ic_gif_white_36dp.png
Normal file
After Width: | Height: | Size: 312 B |
BIN
res/drawable-xxhdpi/ic_view_stream_white_24dp.png
Normal file
After Width: | Height: | Size: 94 B |
BIN
res/drawable-xxhdpi/poweredby_giphy.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
res/drawable-xxxhdpi/ic_dashboard_white_24dp.png
Normal file
After Width: | Height: | Size: 110 B |
BIN
res/drawable-xxxhdpi/ic_gif_white_36dp.png
Normal file
After Width: | Height: | Size: 308 B |
BIN
res/drawable-xxxhdpi/ic_view_stream_white_24dp.png
Normal file
After Width: | Height: | Size: 98 B |
BIN
res/drawable-xxxhdpi/poweredby_giphy.png
Normal file
After Width: | Height: | Size: 6.5 KiB |
@@ -169,6 +169,21 @@
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<org.thoughtcrime.securesms.components.CircleColorImageView
|
||||
android:id="@+id/giphy_button"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:src="@drawable/ic_gif_white_36dp"
|
||||
android:scaleType="center"
|
||||
android:elevation="4dp"
|
||||
app:circleColor="@color/cyan_400"/>
|
||||
|
||||
<TextView android:layout_marginTop="10dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/AttachmentTypeLabel"
|
||||
android:text="GIF"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout android:layout_width="match_parent"
|
||||
|
52
res/layout/giphy_activity.xml
Normal file
@@ -0,0 +1,52 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_width="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<android.support.design.widget.CoordinatorLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_above="@+id/giphy_logo"
|
||||
android:orientation="vertical">
|
||||
|
||||
<android.support.design.widget.AppBarLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:theme="?attr/actionBarStyle"
|
||||
android:background="?attr/colorPrimary">
|
||||
|
||||
<org.thoughtcrime.securesms.giph.ui.GiphyActivityToolbar
|
||||
android:id="@+id/giphy_toolbar"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:background="?attr/colorPrimary"
|
||||
android:theme="?attr/actionBarStyle"
|
||||
app:layout_scrollFlags="scroll|enterAlways"/>
|
||||
|
||||
<android.support.design.widget.TabLayout
|
||||
android:id="@+id/tab_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scrollbars="horizontal"/>
|
||||
|
||||
</android.support.design.widget.AppBarLayout>
|
||||
|
||||
<android.support.v4.view.ViewPager
|
||||
android:id="@+id/giphy_pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
|
||||
|
||||
</android.support.design.widget.CoordinatorLayout>
|
||||
|
||||
<ImageView android:id="@+id/giphy_logo"
|
||||
android:src="@drawable/poweredby_giphy"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:padding="10dp"
|
||||
android:background="@color/black"/>
|
||||
|
||||
</RelativeLayout>
|
86
res/layout/giphy_activity_toolbar.xml
Normal file
@@ -0,0 +1,86 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<LinearLayout android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView android:id="@+id/action_icon"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:gravity="center_vertical"
|
||||
android:clickable="true"
|
||||
android:background="@drawable/circle_touch_highlight_background"
|
||||
android:src="@drawable/ic_search_white_24dp" />
|
||||
|
||||
<LinearLayout android:id="@+id/toggle_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<EditText android:id="@+id/search_view"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="0px"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:layout_marginStart="5dp"
|
||||
android:hint="@string/giphy_activity_toolbar__search_gifs_and_stickers"
|
||||
android:textColor="@color/white"
|
||||
android:textColorHint="@color/white"
|
||||
android:textCursorDrawable="@null"
|
||||
android:maxLines="1"
|
||||
android:imeOptions="actionSearch"
|
||||
android:background="@android:color/transparent"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:gravity="center_vertical"/>
|
||||
|
||||
<ImageView android:id="@+id/search_clear"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:gravity="center_vertical"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:visibility="invisible"
|
||||
android:background="@drawable/circle_touch_highlight_background"
|
||||
android:src="@drawable/ic_clear_white_24dp" />
|
||||
|
||||
<org.thoughtcrime.securesms.components.AnimatingToggle
|
||||
android:id="@+id/button_toggle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:gravity="center">
|
||||
|
||||
<ImageView android:id="@+id/view_grid"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:gravity="center_vertical"
|
||||
android:clickable="true"
|
||||
android:visibility="visible"
|
||||
android:focusable="true"
|
||||
android:background="@drawable/circle_touch_highlight_background"
|
||||
android:src="@drawable/ic_dashboard_white_24dp" />
|
||||
|
||||
<ImageView android:id="@+id/view_stream"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:gravity="center_vertical"
|
||||
android:visibility="gone"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:background="@drawable/circle_touch_highlight_background"
|
||||
android:src="@drawable/ic_view_stream_white_24dp" />
|
||||
|
||||
</org.thoughtcrime.securesms.components.AnimatingToggle>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</merge>
|
27
res/layout/giphy_fragment.xml
Normal file
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<android.support.v7.widget.RecyclerView
|
||||
android:id="@+id/giphy_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:scrollbars="vertical"/>
|
||||
|
||||
<ProgressBar android:id="@+id/loading_progress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:visibility="visible"
|
||||
android:indeterminate="true"/>
|
||||
|
||||
<TextView android:id="@+id/no_results"
|
||||
android:text="@string/giphy_fragment__no_results_found"
|
||||
android:gravity="center"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone"
|
||||
android:layout_gravity="center"/>
|
||||
|
||||
</FrameLayout>
|
22
res/layout/giphy_thumbnail.xml
Normal file
@@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<org.thoughtcrime.securesms.giph.ui.AspectRatioImageView
|
||||
android:id="@+id/thumbnail"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="fitXY" />
|
||||
|
||||
<ProgressBar android:id="@+id/gif_progress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="true"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center"/>
|
||||
|
||||
</FrameLayout>
|
@@ -269,6 +269,14 @@
|
||||
<string name="GcmRefreshJob_Permanent_Signal_communication_failure">Permanent Signal communication failure!</string>
|
||||
<string name="GcmRefreshJob_Signal_was_unable_to_register_with_Google_Play_Services">Signal was unable to register with Google Play Services. Signal messages and calls have been disabled, please try re-registering in Settings > Advanced.</string>
|
||||
|
||||
|
||||
<!-- GiphyActivity -->
|
||||
<string name="GiphyActivity_error_while_retrieving_full_resolution_gif">Error while retrieving full resolution GiF...</string>
|
||||
|
||||
<!-- GiphyFragmentPageAdapter -->
|
||||
<string name="GiphyFragmentPagerAdapter_gifs">GIFs</string>
|
||||
<string name="GiphyFragmentPagerAdapter_stickers">Stickers</string>
|
||||
|
||||
<!-- GroupCreateActivity -->
|
||||
<string name="GroupCreateActivity_actionbar_title">New group</string>
|
||||
<string name="GroupCreateActivity_actionbar_update_title">Update group</string>
|
||||
@@ -751,6 +759,13 @@
|
||||
|
||||
<string name="expiration_weeks_abbreviated">%dw</string>
|
||||
|
||||
<!-- giphy_activity -->
|
||||
<string name="giphy_activity_toolbar__search_gifs_and_stickers">Search GIFs and stickers</string>
|
||||
|
||||
<!-- giphy_fragment -->
|
||||
<string name="giphy_fragment__no_results_found">No results found.</string>
|
||||
|
||||
|
||||
<!-- log_submit_activity -->
|
||||
<string name="log_submit_activity__log_fetch_failed">Could not read the log on your device. You can still use ADB to get a debug log instead.</string>
|
||||
<string name="log_submit_activity__thanks">Thanks for your help!</string>
|
||||
|