mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-28 05:13:53 +01:00
Force upload activity to has always DarkTheme to make it readable
This commit is contained in:
parent
231448c765
commit
9cc574c697
3 changed files with 22 additions and 6 deletions
|
|
@ -4,6 +4,7 @@ import android.app.Activity;
|
|||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.graphics.Color;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.preference.ListPreference;
|
||||
|
|
@ -112,6 +113,13 @@ public class SingleUploadFragment extends Fragment {
|
|||
licenseSpinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
|
||||
@Override
|
||||
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
|
||||
|
||||
//Set selected color to white because it should be readable on random images.
|
||||
TextView selectedText = (TextView) licenseSpinner.getChildAt(0);
|
||||
if (selectedText != null) {
|
||||
selectedText.setTextColor(Color.WHITE);
|
||||
}
|
||||
|
||||
String licenseName = parent.getItemAtPosition(position).toString();
|
||||
|
||||
String license = Prefs.Licenses.CC_BY_SA_3; // default value
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue