Merge branch 'develop' into 'develop'
Change animation on conversation activity && Fix zero tool length if from shared contents && UI Improvement See merge request tom79/mastalab!2105
This commit is contained in:
commit
5f846f72a2
|
@ -185,6 +185,7 @@ public class ShowConversationActivity extends BaseActivity implements OnRetriev
|
||||||
intent.putExtras(b);
|
intent.putExtras(b);
|
||||||
finish();
|
finish();
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
|
overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
action_unhide.setOnClickListener(new View.OnClickListener() {
|
action_unhide.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@ -211,6 +212,8 @@ public class ShowConversationActivity extends BaseActivity implements OnRetriev
|
||||||
intent.putExtras(b);
|
intent.putExtras(b);
|
||||||
finish();
|
finish();
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
|
overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -292,6 +295,7 @@ public class ShowConversationActivity extends BaseActivity implements OnRetriev
|
||||||
intent.putExtras(b);
|
intent.putExtras(b);
|
||||||
finish();
|
finish();
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
|
overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -157,6 +157,7 @@ import fr.gouv.etalab.mastodon.sqlite.StatusStoredDAO;
|
||||||
import static fr.gouv.etalab.mastodon.helper.Helper.HOME_TIMELINE_INTENT;
|
import static fr.gouv.etalab.mastodon.helper.Helper.HOME_TIMELINE_INTENT;
|
||||||
import static fr.gouv.etalab.mastodon.helper.Helper.INTENT_ACTION;
|
import static fr.gouv.etalab.mastodon.helper.Helper.INTENT_ACTION;
|
||||||
import static fr.gouv.etalab.mastodon.helper.Helper.THEME_LIGHT;
|
import static fr.gouv.etalab.mastodon.helper.Helper.THEME_LIGHT;
|
||||||
|
import static fr.gouv.etalab.mastodon.helper.Helper.changeButtonTextColor;
|
||||||
import static fr.gouv.etalab.mastodon.helper.Helper.changeDrawableColor;
|
import static fr.gouv.etalab.mastodon.helper.Helper.changeDrawableColor;
|
||||||
import static fr.gouv.etalab.mastodon.helper.Helper.convertDpToPixel;
|
import static fr.gouv.etalab.mastodon.helper.Helper.convertDpToPixel;
|
||||||
|
|
||||||
|
@ -761,6 +762,8 @@ public class TootActivity extends BaseActivity implements OnPostActionInterface,
|
||||||
displayPollPopup();
|
displayPollPopup();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
toot_space_left.setText(String.valueOf(toot_content.length()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -2881,8 +2884,6 @@ public class TootActivity extends BaseActivity implements OnPostActionInterface,
|
||||||
Toasty.error(getApplicationContext(), getString(R.string.toast_error), Toast.LENGTH_LONG).show();
|
Toasty.error(getApplicationContext(), getString(R.string.toast_error), Toast.LENGTH_LONG).show();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void changeColor(){
|
private void changeColor(){
|
||||||
final SharedPreferences sharedpreferences = getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
|
final SharedPreferences sharedpreferences = getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
|
||||||
int theme = sharedpreferences.getInt(Helper.SET_THEME, Helper.THEME_DARK);
|
int theme = sharedpreferences.getInt(Helper.SET_THEME, Helper.THEME_DARK);
|
||||||
|
@ -2896,6 +2897,13 @@ public class TootActivity extends BaseActivity implements OnPostActionInterface,
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_skip_next, R.color.dark_text);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_skip_next, R.color.dark_text);
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_check, R.color.dark_text);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_check, R.color.dark_text);
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.emoji_one_category_smileysandpeople, R.color.dark_text);
|
changeDrawableColor(TootActivity.this, R.drawable.emoji_one_category_smileysandpeople, R.color.dark_text);
|
||||||
|
//bottom action
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_picture), R.color.dark_text);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.poll_action), R.color.dark_text);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_visibility), R.color.dark_text);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_emoji), R.color.dark_text);
|
||||||
|
changeButtonTextColor(TootActivity.this, findViewById(R.id.toot_cw), R.color.dark_text);
|
||||||
|
|
||||||
}else {
|
}else {
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_public_toot, R.color.white);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_public_toot, R.color.white);
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_lock_open_toot, R.color.white);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_lock_open_toot, R.color.white);
|
||||||
|
@ -2906,6 +2914,13 @@ public class TootActivity extends BaseActivity implements OnPostActionInterface,
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_skip_next, R.color.white);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_skip_next, R.color.white);
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.ic_check, R.color.white);
|
changeDrawableColor(TootActivity.this, R.drawable.ic_check, R.color.white);
|
||||||
changeDrawableColor(TootActivity.this, R.drawable.emoji_one_category_smileysandpeople, R.color.black);
|
changeDrawableColor(TootActivity.this, R.drawable.emoji_one_category_smileysandpeople, R.color.black);
|
||||||
|
//bottom action
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_picture), R.color.black);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.poll_action), R.color.black);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_visibility), R.color.black);
|
||||||
|
changeDrawableColor(TootActivity.this, findViewById(R.id.toot_emoji), R.color.black);
|
||||||
|
changeButtonTextColor(TootActivity.this, findViewById(R.id.toot_cw), R.color.black);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -95,6 +95,7 @@ import android.webkit.MimeTypeMap;
|
||||||
import android.webkit.URLUtil;
|
import android.webkit.URLUtil;
|
||||||
import android.webkit.WebSettings;
|
import android.webkit.WebSettings;
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
|
import android.widget.Button;
|
||||||
import android.widget.ImageButton;
|
import android.widget.ImageButton;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
import android.widget.LinearLayout;
|
import android.widget.LinearLayout;
|
||||||
|
@ -2303,6 +2304,14 @@ public class Helper {
|
||||||
imageButton.setColorFilter(context.getResources().getColor(hexaColor));
|
imageButton.setColorFilter(context.getResources().getColor(hexaColor));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* change color of a drawable
|
||||||
|
* @param button int the button
|
||||||
|
* @param hexaColor example 0xffff00
|
||||||
|
*/
|
||||||
|
public static void changeButtonTextColor(Context context, Button button, int hexaColor){
|
||||||
|
button.setTextColor(context.getResources().getColor(hexaColor));
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* Returns the current locale of the device
|
* Returns the current locale of the device
|
||||||
* @param context Context
|
* @param context Context
|
||||||
|
|
|
@ -0,0 +1,28 @@
|
||||||
|
package fr.gouv.etalab.mastodon.helper;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.AttributeSet;
|
||||||
|
|
||||||
|
public class SquareButton extends android.support.v7.widget.AppCompatButton {
|
||||||
|
|
||||||
|
public SquareButton(Context context) {
|
||||||
|
super(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SquareButton(Context context, AttributeSet attrs) {
|
||||||
|
super(context, attrs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SquareButton(Context context, AttributeSet attrs, int defStyleAttr) {
|
||||||
|
super(context, attrs, defStyleAttr);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
|
||||||
|
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
|
||||||
|
int height = MeasureSpec.getSize(heightMeasureSpec);
|
||||||
|
super.onMeasure(
|
||||||
|
MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY),
|
||||||
|
MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY));
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,28 @@
|
||||||
|
package fr.gouv.etalab.mastodon.helper;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.AttributeSet;
|
||||||
|
import android.widget.ImageButton;
|
||||||
|
|
||||||
|
public class SquareImageButton extends android.support.v7.widget.AppCompatImageButton {
|
||||||
|
public SquareImageButton(Context context) {
|
||||||
|
super(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SquareImageButton(Context context, AttributeSet attrs) {
|
||||||
|
super(context, attrs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SquareImageButton(Context context, AttributeSet attrs, int defStyleAttr) {
|
||||||
|
super(context, attrs, defStyleAttr);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
|
||||||
|
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
|
||||||
|
int height = MeasureSpec.getSize(heightMeasureSpec);
|
||||||
|
super.onMeasure(
|
||||||
|
MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY),
|
||||||
|
MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY));
|
||||||
|
}
|
||||||
|
}
|
|
@ -4,6 +4,6 @@
|
||||||
android:viewportWidth="24.0"
|
android:viewportWidth="24.0"
|
||||||
android:viewportHeight="24.0">
|
android:viewportHeight="24.0">
|
||||||
<path
|
<path
|
||||||
android:fillColor="#FF000000"
|
android:fillColor="#FFFFFFFF"
|
||||||
android:pathData="M12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM11,19.93c-3.95,-0.49 -7,-3.85 -7,-7.93 0,-0.62 0.08,-1.21 0.21,-1.79L9,15v1c0,1.1 0.9,2 2,2v1.93zM17.9,17.39c-0.26,-0.81 -1,-1.39 -1.9,-1.39h-1v-3c0,-0.55 -0.45,-1 -1,-1L8,12v-2h2c0.55,0 1,-0.45 1,-1L11,7h2c1.1,0 2,-0.9 2,-2v-0.41c2.93,1.19 5,4.06 5,7.41 0,2.08 -0.8,3.97 -2.1,5.39z"/>
|
android:pathData="M12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM11,19.93c-3.95,-0.49 -7,-3.85 -7,-7.93 0,-0.62 0.08,-1.21 0.21,-1.79L9,15v1c0,1.1 0.9,2 2,2v1.93zM17.9,17.39c-0.26,-0.81 -1,-1.39 -1.9,-1.39h-1v-3c0,-0.55 -0.45,-1 -1,-1L8,12v-2h2c0.55,0 1,-0.45 1,-1L11,7h2c1.1,0 2,-0.9 2,-2v-0.41c2.93,1.19 5,4.06 5,7.41 0,2.08 -0.8,3.97 -2.1,5.39z"/>
|
||||||
</vector>
|
</vector>
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 8.7 KiB |
|
@ -98,16 +98,22 @@
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/toot_picture"
|
android:id="@+id/toot_picture"
|
||||||
android:layout_width="50dp"
|
android:layout_width="50dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="50dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:padding="5dp"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
style="@style/Base.Widget.AppCompat.Button.Colored"
|
||||||
|
android:background="@color/transparent"
|
||||||
android:src="@drawable/ic_insert_photo"
|
android:src="@drawable/ic_insert_photo"
|
||||||
android:contentDescription="@string/toot_select_image" />
|
android:contentDescription="@string/toot_select_image" />
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/poll_action"
|
android:id="@+id/poll_action"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
android:layout_width="50dp"
|
android:layout_width="50dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="50dp"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
style="@style/Base.Widget.AppCompat.Button.Colored"
|
||||||
|
android:background="@color/transparent"
|
||||||
android:src="@drawable/ic_view_list_poll"
|
android:src="@drawable/ic_view_list_poll"
|
||||||
android:contentDescription="@string/poll" />
|
android:contentDescription="@string/poll" />
|
||||||
<ImageButton
|
<ImageButton
|
||||||
|
@ -115,30 +121,42 @@
|
||||||
android:layout_marginStart="5dp"
|
android:layout_marginStart="5dp"
|
||||||
android:id="@+id/toot_visibility"
|
android:id="@+id/toot_visibility"
|
||||||
android:layout_width="50dp"
|
android:layout_width="50dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="50dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:padding="5dp"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
style="@style/Base.Widget.AppCompat.Button.Colored"
|
||||||
|
android:background="@color/transparent"
|
||||||
android:src="@drawable/ic_public"
|
android:src="@drawable/ic_public"
|
||||||
android:contentDescription="@string/toot_visibility_tilte"/>
|
android:contentDescription="@string/toot_visibility_tilte"/>
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/toot_cw"
|
android:id="@+id/toot_cw"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:layout_marginStart="5dp"
|
||||||
android:padding="5dp"
|
android:padding="5dp"
|
||||||
android:text="@string/cw"
|
android:text="@string/cw"
|
||||||
|
android:textSize="20sp"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
style="?attr/borderlessColored"
|
style="@style/Widget.AppCompat.Button.Colored"
|
||||||
|
android:background="@color/transparent"
|
||||||
android:layout_width="50dp"
|
android:layout_width="50dp"
|
||||||
android:layout_height="50dp" />
|
android:layout_height="50dp"
|
||||||
|
android:scaleType="centerCrop"/>
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/toot_emoji"
|
android:id="@+id/toot_emoji"
|
||||||
android:minHeight="0dp"
|
android:minHeight="0dp"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:layout_marginStart="5dp"
|
||||||
android:minWidth="0dp"
|
android:minWidth="0dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:padding="2dp"
|
android:padding="5dp"
|
||||||
android:scaleType="fitXY"
|
|
||||||
android:contentDescription="@string/emoji_picker"
|
android:contentDescription="@string/emoji_picker"
|
||||||
android:src="@drawable/emoji_one_category_smileysandpeople"
|
android:src="@drawable/ic_emoji_selector"
|
||||||
style="?attr/borderlessColored"
|
style="@style/Widget.AppCompat.Button.Colored"
|
||||||
android:layout_width="30dp"
|
android:background="@color/transparent"
|
||||||
android:layout_height="30dp"
|
android:layout_width="50dp"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
/>
|
/>
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/toot_space_left"
|
android:id="@+id/toot_space_left"
|
||||||
|
|
|
@ -103,46 +103,57 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_margin="5dp"
|
|
||||||
android:src="@drawable/ic_first_page"
|
|
||||||
android:id="@+id/media_prev"
|
android:id="@+id/media_prev"
|
||||||
android:layout_centerVertical="true"
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_alignParentLeft="true"
|
android:layout_alignParentLeft="true"
|
||||||
android:layout_width="20dp"
|
|
||||||
android:layout_height="20dp"
|
|
||||||
android:contentDescription="@string/previous" />
|
|
||||||
<ImageView
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_margin="5dp"
|
|
||||||
android:id="@+id/media_next"
|
|
||||||
android:src="@drawable/ic_last_page"
|
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginStart="5dp"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="5dp"
|
||||||
|
android:contentDescription="@string/previous"
|
||||||
|
android:src="@drawable/ic_first_page"
|
||||||
|
android:visibility="gone" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/media_next"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
android:layout_alignParentEnd="true"
|
android:layout_alignParentEnd="true"
|
||||||
android:layout_alignParentRight="true"
|
android:layout_alignParentRight="true"
|
||||||
android:layout_width="20dp"
|
android:layout_centerVertical="true"
|
||||||
android:layout_height="20dp"
|
android:layout_marginStart="5dp"
|
||||||
android:contentDescription="@string/next" />
|
android:layout_marginLeft="5dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="5dp"
|
||||||
|
android:contentDescription="@string/next"
|
||||||
|
android:src="@drawable/ic_last_page"
|
||||||
|
android:visibility="gone" />
|
||||||
|
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/media_close"
|
android:id="@+id/media_close"
|
||||||
android:layout_alignParentTop="true"
|
android:layout_width="35dp"
|
||||||
android:layout_alignParentLeft="true"
|
android:layout_height="35dp"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
app:layout_anchorGravity="top|left"
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:background="@color/transparent"
|
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
android:layout_marginTop="5dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_width="wrap_content"
|
android:background="@color/transparent"
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:src="@drawable/ic_close"
|
|
||||||
android:contentDescription="@string/close"
|
android:contentDescription="@string/close"
|
||||||
/>
|
android:scaleType="fitXY"
|
||||||
|
android:src="@drawable/ic_close"
|
||||||
|
app:layout_anchorGravity="top|left" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -161,24 +172,27 @@
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:background="@color/transparent"
|
android:background="@color/transparent"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
android:layout_marginTop="5dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="30dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="30dp"
|
||||||
android:src="@drawable/ic_share_media"
|
android:src="@drawable/ic_share_media"
|
||||||
|
android:scaleType="fitXY"
|
||||||
android:contentDescription="@string/share"
|
android:contentDescription="@string/share"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/media_save"
|
android:id="@+id/media_save"
|
||||||
|
android:scaleType="fitXY"
|
||||||
android:layout_marginStart="20dp"
|
android:layout_marginStart="20dp"
|
||||||
android:background="@color/transparent"
|
android:background="@color/transparent"
|
||||||
android:layout_marginLeft="20dp"
|
android:layout_marginLeft="20dp"
|
||||||
android:layout_marginTop="5dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_width="wrap_content"
|
android:layout_marginRight="15dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_width="30dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
android:src="@drawable/ic_save_white"
|
android:src="@drawable/ic_save_white"
|
||||||
android:contentDescription="@string/download"
|
android:contentDescription="@string/download"
|
||||||
/>
|
android:layout_marginEnd="10dp" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -46,126 +46,143 @@
|
||||||
android:minLines="4"
|
android:minLines="4"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:layout_height="0dp" />
|
android:layout_height="0dp" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:visibility="gone"
|
|
||||||
android:id="@+id/progress_bar_container"
|
android:id="@+id/progress_bar_container"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="gone">
|
||||||
|
|
||||||
<ProgressBar
|
<ProgressBar
|
||||||
style="@style/Base.Widget.AppCompat.ProgressBar.Horizontal"
|
|
||||||
android:indeterminate="false"
|
|
||||||
android:id="@+id/upload_progress"
|
android:id="@+id/upload_progress"
|
||||||
|
style="@style/Base.Widget.AppCompat.ProgressBar.Horizontal"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:max="100"
|
|
||||||
android:progress="0"
|
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
/>
|
android:indeterminate="false"
|
||||||
|
android:max="100"
|
||||||
|
android:progress="0" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/toolbar_text"
|
android:id="@+id/toolbar_text"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:textColor="@color/dark_text"
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center"
|
|
||||||
android:textSize="12sp"
|
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:layout_height="wrap_content" />
|
android:gravity="center"
|
||||||
|
android:textColor="@color/dark_text"
|
||||||
|
android:textSize="12sp" />
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<HorizontalScrollView
|
<HorizontalScrollView
|
||||||
android:id="@+id/picture_scrollview"
|
android:id="@+id/picture_scrollview"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
>
|
android:visibility="gone">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:padding="5dp"
|
|
||||||
android:id="@+id/toot_picture_container"
|
android:id="@+id/toot_picture_container"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:maxHeight="100dp"
|
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
|
android:maxHeight="100dp"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
>
|
android:padding="5dp"></LinearLayout>
|
||||||
</LinearLayout>
|
|
||||||
</HorizontalScrollView>
|
</HorizontalScrollView>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:orientation="horizontal"
|
android:layout_height="wrap_content"
|
||||||
android:layout_height="wrap_content">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/toot_picture"
|
android:id="@+id/toot_picture"
|
||||||
android:layout_width="50dp"
|
android:layout_width="40dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="40dp"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
android:adjustViewBounds="true"
|
||||||
android:src="@drawable/ic_insert_photo"
|
android:background="@color/transparent"
|
||||||
android:contentDescription="@string/toot_select_image" />
|
android:contentDescription="@string/toot_select_image"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/ic_insert_photo" />
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/poll_action"
|
android:id="@+id/poll_action"
|
||||||
android:visibility="gone"
|
android:layout_width="40dp"
|
||||||
android:layout_width="50dp"
|
android:layout_height="40dp"
|
||||||
android:layout_height="wrap_content"
|
android:adjustViewBounds="true"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
android:background="@color/transparent"
|
||||||
|
android:contentDescription="@string/poll"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
android:src="@drawable/ic_view_list_poll"
|
android:src="@drawable/ic_view_list_poll"
|
||||||
android:contentDescription="@string/poll" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:layout_marginLeft="5dp"
|
|
||||||
android:layout_marginStart="5dp"
|
|
||||||
android:id="@+id/toot_visibility"
|
android:id="@+id/toot_visibility"
|
||||||
android:layout_width="50dp"
|
android:layout_width="40dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="40dp"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
android:adjustViewBounds="true"
|
||||||
android:src="@drawable/ic_public"
|
android:background="@color/transparent"
|
||||||
android:contentDescription="@string/toot_visibility_tilte" />
|
android:contentDescription="@string/toot_visibility_tilte"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/ic_public" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/toot_cw"
|
android:id="@+id/toot_cw"
|
||||||
android:padding="5dp"
|
|
||||||
android:text="@string/cw"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
style="?attr/borderlessColored"
|
|
||||||
android:layout_width="40dp"
|
android:layout_width="40dp"
|
||||||
android:layout_height="40dp" />
|
android:layout_height="40dp"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:background="@color/transparent"
|
||||||
|
android:text="@string/cw"
|
||||||
|
android:textSize="20sp" />
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/toot_emoji"
|
android:id="@+id/toot_emoji"
|
||||||
android:minHeight="0dp"
|
android:layout_width="40dp"
|
||||||
android:minWidth="0dp"
|
android:layout_height="40dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:padding="2dp"
|
android:adjustViewBounds="true"
|
||||||
android:scaleType="fitXY"
|
android:background="@color/transparent"
|
||||||
android:src="@drawable/emoji_one_category_smileysandpeople"
|
|
||||||
style="?attr/borderlessColored"
|
|
||||||
android:layout_width="30dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:contentDescription="@string/emoji_picker"
|
android:contentDescription="@string/emoji_picker"
|
||||||
/>
|
android:minWidth="0dp"
|
||||||
|
android:minHeight="0dp"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/ic_emoji_selector" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/toot_space_left"
|
android:id="@+id/toot_space_left"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:textColor="?colorAccent"
|
android:layout_height="40dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:layout_gravity="center"
|
android:textColor="?colorAccent" />
|
||||||
android:layout_height="40dp" />
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/toot_it"
|
android:id="@+id/toot_it"
|
||||||
android:padding="5dp"
|
style="@style/Widget.AppCompat.Button.Colored"
|
||||||
android:text="@string/toot_it"
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="40dp"
|
||||||
android:layout_gravity="end"
|
android:layout_gravity="end"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
style="@style/Base.Widget.AppCompat.Button.Colored"
|
android:padding="5dp"
|
||||||
android:layout_width="wrap_content"
|
android:text="@string/toot_it" />
|
||||||
android:layout_height="wrap_content" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<CheckBox
|
<CheckBox
|
||||||
android:text="@string/toot_sensitive"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:id="@+id/toot_sensitive"
|
android:id="@+id/toot_sensitive"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/toot_sensitive"
|
||||||
|
android:visibility="gone" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
|
|
@ -392,5 +392,4 @@
|
||||||
<style name="Shape.Dark" parent="AppThemeDark">
|
<style name="Shape.Dark" parent="AppThemeDark">
|
||||||
<item name="android:background">@drawable/shape_border_bottom_settings_dark</item>
|
<item name="android:background">@drawable/shape_border_bottom_settings_dark</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
|
Loading…
Reference in New Issue