mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
Merge remote-tracking branch 'refs/remotes/commons-app/master'
This commit is contained in:
commit
b735f62bf9
28 changed files with 306 additions and 629 deletions
|
|
@ -3,10 +3,15 @@ addons:
|
||||||
apt:
|
apt:
|
||||||
packages:
|
packages:
|
||||||
- w3m
|
- w3m
|
||||||
|
cache:
|
||||||
|
directories:
|
||||||
|
- ${TRAVIS_BUILD_DIR}/gradle/caches/
|
||||||
|
- ${TRAVIS_BUILD_DIR}/gradle/wrapper/dists/
|
||||||
env:
|
env:
|
||||||
global:
|
global:
|
||||||
- ANDROID_TARGET=android-22
|
- ANDROID_TARGET=android-22
|
||||||
- ANDROID_ABI=armeabi-v7a
|
- ANDROID_ABI=armeabi-v7a
|
||||||
|
- ADB_INSTALL_TIMEOUT=12 # in minutes
|
||||||
android:
|
android:
|
||||||
components:
|
components:
|
||||||
- platform-tools
|
- platform-tools
|
||||||
|
|
@ -19,10 +24,10 @@ android:
|
||||||
- sys-img-${ANDROID_ABI}-${ANDROID_TARGET}
|
- sys-img-${ANDROID_ABI}-${ANDROID_TARGET}
|
||||||
before_script:
|
before_script:
|
||||||
- echo no | android create avd --force -n test -t $ANDROID_TARGET --abi $ANDROID_ABI
|
- echo no | android create avd --force -n test -t $ANDROID_TARGET --abi $ANDROID_ABI
|
||||||
- emulator -avd test -no-audio -no-window &
|
- emulator -avd test -no-audio -no-window -no-boot-anim &
|
||||||
- android-wait-for-emulator
|
- android-wait-for-emulator
|
||||||
script:
|
script:
|
||||||
- ./gradlew check connectedCheck jacocoTestReport -stacktrace
|
- ./gradlew clean check connectedCheck jacocoTestReport --stacktrace
|
||||||
after_success:
|
after_success:
|
||||||
- bash <(curl -s https://codecov.io/bash)
|
- bash <(curl -s https://codecov.io/bash)
|
||||||
after_failure:
|
after_failure:
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ dependencies {
|
||||||
compile "com.jakewharton:butterknife:$BUTTERKNIFE_VERSION"
|
compile "com.jakewharton:butterknife:$BUTTERKNIFE_VERSION"
|
||||||
annotationProcessor "com.jakewharton:butterknife-compiler:$BUTTERKNIFE_VERSION"
|
annotationProcessor "com.jakewharton:butterknife-compiler:$BUTTERKNIFE_VERSION"
|
||||||
compile 'com.jakewharton.timber:timber:4.5.1'
|
compile 'com.jakewharton.timber:timber:4.5.1'
|
||||||
compile ('com.mapbox.mapboxsdk:mapbox-android-sdk:5.0.2@aar'){
|
compile ('com.mapbox.mapboxsdk:mapbox-android-sdk:5.1.0@aar'){
|
||||||
transitive=true
|
transitive=true
|
||||||
}
|
}
|
||||||
compile 'com.facebook.fresco:fresco:1.3.0'
|
compile 'com.facebook.fresco:fresco:1.3.0'
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@ import fr.free.nrw.commons.HandlerService;
|
||||||
import fr.free.nrw.commons.Media;
|
import fr.free.nrw.commons.Media;
|
||||||
import fr.free.nrw.commons.R;
|
import fr.free.nrw.commons.R;
|
||||||
import fr.free.nrw.commons.auth.AuthenticatedActivity;
|
import fr.free.nrw.commons.auth.AuthenticatedActivity;
|
||||||
import fr.free.nrw.commons.hamburger.HamburgerMenuContainer;
|
|
||||||
import fr.free.nrw.commons.media.MediaDetailPagerFragment;
|
import fr.free.nrw.commons.media.MediaDetailPagerFragment;
|
||||||
import fr.free.nrw.commons.settings.Prefs;
|
import fr.free.nrw.commons.settings.Prefs;
|
||||||
import fr.free.nrw.commons.upload.UploadService;
|
import fr.free.nrw.commons.upload.UploadService;
|
||||||
|
|
@ -48,8 +47,7 @@ public class ContributionsActivity
|
||||||
AdapterView.OnItemClickListener,
|
AdapterView.OnItemClickListener,
|
||||||
MediaDetailPagerFragment.MediaDetailProvider,
|
MediaDetailPagerFragment.MediaDetailProvider,
|
||||||
FragmentManager.OnBackStackChangedListener,
|
FragmentManager.OnBackStackChangedListener,
|
||||||
ContributionsListFragment.SourceRefresher,
|
ContributionsListFragment.SourceRefresher {
|
||||||
HamburgerMenuContainer {
|
|
||||||
|
|
||||||
private Cursor allContributions;
|
private Cursor allContributions;
|
||||||
private ContributionsListFragment contributionsList;
|
private ContributionsListFragment contributionsList;
|
||||||
|
|
|
||||||
|
|
@ -1,9 +0,0 @@
|
||||||
package fr.free.nrw.commons.hamburger;
|
|
||||||
|
|
||||||
import android.support.v7.app.ActionBarDrawerToggle;
|
|
||||||
|
|
||||||
public interface HamburgerMenuContainer {
|
|
||||||
void setDrawerListener(ActionBarDrawerToggle listener);
|
|
||||||
void toggleDrawer();
|
|
||||||
boolean isDrawerVisible();
|
|
||||||
}
|
|
||||||
|
|
@ -1,174 +0,0 @@
|
||||||
package fr.free.nrw.commons.hamburger;
|
|
||||||
|
|
||||||
import android.content.ActivityNotFoundException;
|
|
||||||
import android.content.DialogInterface;
|
|
||||||
import android.content.Intent;
|
|
||||||
import android.os.Bundle;
|
|
||||||
import android.support.v4.app.Fragment;
|
|
||||||
import android.support.v4.widget.DrawerLayout;
|
|
||||||
import android.support.v7.app.ActionBarDrawerToggle;
|
|
||||||
import android.support.v7.app.AlertDialog;
|
|
||||||
import android.view.LayoutInflater;
|
|
||||||
import android.view.View;
|
|
||||||
import android.view.ViewGroup;
|
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.LinearLayout;
|
|
||||||
import android.widget.RelativeLayout;
|
|
||||||
import android.widget.Toast;
|
|
||||||
|
|
||||||
import butterknife.BindView;
|
|
||||||
import butterknife.ButterKnife;
|
|
||||||
import butterknife.OnClick;
|
|
||||||
import fr.free.nrw.commons.AboutActivity;
|
|
||||||
import fr.free.nrw.commons.BuildConfig;
|
|
||||||
import fr.free.nrw.commons.CommonsApplication;
|
|
||||||
import fr.free.nrw.commons.R;
|
|
||||||
import fr.free.nrw.commons.WelcomeActivity;
|
|
||||||
import fr.free.nrw.commons.auth.LoginActivity;
|
|
||||||
import fr.free.nrw.commons.contributions.ContributionsActivity;
|
|
||||||
import fr.free.nrw.commons.nearby.NearbyActivity;
|
|
||||||
import fr.free.nrw.commons.settings.SettingsActivity;
|
|
||||||
|
|
||||||
|
|
||||||
public class NavigationBaseFragment extends Fragment {
|
|
||||||
@BindView(R.id.pictureOfTheDay)
|
|
||||||
ImageView pictureOfTheDay;
|
|
||||||
|
|
||||||
@BindView(R.id.upload_item)
|
|
||||||
LinearLayout uploadItem;
|
|
||||||
|
|
||||||
@BindView(R.id.nearby_item)
|
|
||||||
LinearLayout nearbyItem;
|
|
||||||
|
|
||||||
@BindView(R.id.about_item)
|
|
||||||
LinearLayout aboutItem;
|
|
||||||
|
|
||||||
@BindView(R.id.settings_item)
|
|
||||||
LinearLayout settingsItem;
|
|
||||||
|
|
||||||
@BindView(R.id.feedback_item)
|
|
||||||
LinearLayout feedbackItem;
|
|
||||||
|
|
||||||
@BindView(R.id.logout_item)
|
|
||||||
LinearLayout logoutItem;
|
|
||||||
|
|
||||||
@BindView(R.id.introduction_item)
|
|
||||||
LinearLayout introductionItem;
|
|
||||||
|
|
||||||
private DrawerLayout drawerLayout;
|
|
||||||
private RelativeLayout drawerPane;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public View onCreateView(LayoutInflater inflater,
|
|
||||||
ViewGroup container,
|
|
||||||
Bundle savedInstanceState) {
|
|
||||||
View hamburgerView = inflater.inflate(R.layout.navigation_drawer_menu, container, false);
|
|
||||||
ButterKnife.bind(this, hamburgerView);
|
|
||||||
showPictureOfTheDay();
|
|
||||||
setupHamburgerMenu();
|
|
||||||
return hamburgerView;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void showPictureOfTheDay() {
|
|
||||||
pictureOfTheDay.setImageDrawable(getResources().getDrawable(R.drawable.commons_logo_large));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onResume() {
|
|
||||||
super.onResume();
|
|
||||||
}
|
|
||||||
|
|
||||||
private void setupHamburgerMenu() {
|
|
||||||
ActionBarDrawerToggle drawerToggle = new ActionBarDrawerToggle(getActivity(),
|
|
||||||
drawerLayout, R.string.ok, R.string.cancel);
|
|
||||||
if (getActivity() instanceof HamburgerMenuContainer) {
|
|
||||||
((HamburgerMenuContainer) getActivity()).setDrawerListener(drawerToggle);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.upload_item)
|
|
||||||
protected void onUploadItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
ContributionsActivity.startYourself(getActivity());
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.settings_item)
|
|
||||||
protected void onSettingsItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
SettingsActivity.startYourself(getActivity());
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.about_item)
|
|
||||||
protected void onAboutItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
AboutActivity.startYourself(getActivity());
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.nearby_item)
|
|
||||||
protected void onNearbyItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
NearbyActivity.startYourself(getActivity());
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.introduction_item)
|
|
||||||
protected void onInfoItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
WelcomeActivity.startYourself(getActivity());
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.feedback_item)
|
|
||||||
protected void onFeedbackItemClicked() {
|
|
||||||
closeDrawer();
|
|
||||||
Intent feedbackIntent = new Intent(Intent.ACTION_SEND);
|
|
||||||
feedbackIntent.setType("message/rfc822");
|
|
||||||
feedbackIntent.putExtra(Intent.EXTRA_EMAIL,
|
|
||||||
new String[]{CommonsApplication.FEEDBACK_EMAIL});
|
|
||||||
feedbackIntent.putExtra(Intent.EXTRA_SUBJECT,
|
|
||||||
String.format(CommonsApplication.FEEDBACK_EMAIL_SUBJECT,
|
|
||||||
BuildConfig.VERSION_NAME));
|
|
||||||
try {
|
|
||||||
startActivity(feedbackIntent);
|
|
||||||
} catch (ActivityNotFoundException e) {
|
|
||||||
Toast.makeText(getActivity(), R.string.no_email_client, Toast.LENGTH_SHORT).show();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@OnClick(R.id.logout_item)
|
|
||||||
protected void onLogoutItemClicked() {
|
|
||||||
AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(getActivity());
|
|
||||||
alertDialogBuilder.setMessage(R.string.logout_verification)
|
|
||||||
.setCancelable(false)
|
|
||||||
.setPositiveButton(R.string.yes,
|
|
||||||
new DialogInterface.OnClickListener() {
|
|
||||||
public void onClick(DialogInterface dialog, int id) {
|
|
||||||
((CommonsApplication)getActivity().getApplicationContext())
|
|
||||||
.clearApplicationData(getContext());
|
|
||||||
Intent nearbyIntent = new Intent
|
|
||||||
(getActivity(), LoginActivity.class);
|
|
||||||
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
||||||
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
|
||||||
startActivity(nearbyIntent);
|
|
||||||
getActivity().finish();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
alertDialogBuilder.setNegativeButton(R.string.no,
|
|
||||||
new DialogInterface.OnClickListener() {
|
|
||||||
public void onClick(DialogInterface dialog, int id) {
|
|
||||||
dialog.cancel();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
AlertDialog alert = alertDialogBuilder.create();
|
|
||||||
alert.show();
|
|
||||||
}
|
|
||||||
|
|
||||||
private void closeDrawer() {
|
|
||||||
if (drawerLayout != null) {
|
|
||||||
drawerLayout.closeDrawer(drawerPane);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setDrawerLayout(DrawerLayout drawerLayout, RelativeLayout drawerPane) {
|
|
||||||
this.drawerLayout = drawerLayout;
|
|
||||||
this.drawerPane = drawerPane;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -56,9 +56,6 @@ public class NearbyActivity extends NavigationBaseActivity {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_nearby);
|
setContentView(R.layout.activity_nearby);
|
||||||
ButterKnife.bind(this);
|
ButterKnife.bind(this);
|
||||||
if (getSupportActionBar() != null) {
|
|
||||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
|
||||||
}
|
|
||||||
checkLocationPermission();
|
checkLocationPermission();
|
||||||
bundle = new Bundle();
|
bundle = new Bundle();
|
||||||
initDrawer();
|
initDrawer();
|
||||||
|
|
|
||||||
|
|
@ -121,7 +121,7 @@ public class NearbyInfoDialog extends OverlayDialog {
|
||||||
NearbyInfoDialog mDialog = new NearbyInfoDialog();
|
NearbyInfoDialog mDialog = new NearbyInfoDialog();
|
||||||
Bundle bundle = new Bundle();
|
Bundle bundle = new Bundle();
|
||||||
bundle.putString(ARG_TITLE, place.name);
|
bundle.putString(ARG_TITLE, place.name);
|
||||||
bundle.putString(ARG_DESC, place.description);
|
bundle.putString(ARG_DESC, place.getDescription().getText());
|
||||||
bundle.putDouble(ARG_LATITUDE, place.location.getLatitude());
|
bundle.putDouble(ARG_LATITUDE, place.location.getLatitude());
|
||||||
bundle.putDouble(ARG_LONGITUDE, place.location.getLongitude());
|
bundle.putDouble(ARG_LONGITUDE, place.location.getLongitude());
|
||||||
bundle.putParcelable(ARG_SITE_LINK, place.siteLinks);
|
bundle.putParcelable(ARG_SITE_LINK, place.siteLinks);
|
||||||
|
|
|
||||||
|
|
@ -122,7 +122,7 @@ public class NearbyPlaces {
|
||||||
|
|
||||||
places.add(new Place(
|
places.add(new Place(
|
||||||
name,
|
name,
|
||||||
type, // list
|
Place.Description.fromText(type), // list
|
||||||
type, // details
|
type, // details
|
||||||
Uri.parse(icon),
|
Uri.parse(icon),
|
||||||
new LatLng(latitude, longitude, 0),
|
new LatLng(latitude, longitude, 0),
|
||||||
|
|
@ -184,7 +184,7 @@ public class NearbyPlaces {
|
||||||
|
|
||||||
places.add(new Place(
|
places.add(new Place(
|
||||||
name,
|
name,
|
||||||
type, // list
|
Place.Description.fromText(type), // list
|
||||||
type, // details
|
type, // details
|
||||||
null,
|
null,
|
||||||
new LatLng(latitude, longitude, 0),
|
new LatLng(latitude, longitude, 0),
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,6 @@ import butterknife.BindView;
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
import fr.free.nrw.commons.R;
|
import fr.free.nrw.commons.R;
|
||||||
import fr.free.nrw.commons.ViewHolder;
|
import fr.free.nrw.commons.ViewHolder;
|
||||||
import fr.free.nrw.commons.utils.ResourceUtils;
|
|
||||||
|
|
||||||
public class NearbyViewHolder implements ViewHolder<Place> {
|
public class NearbyViewHolder implements ViewHolder<Place> {
|
||||||
@BindView(R.id.tvName) TextView tvName;
|
@BindView(R.id.tvName) TextView tvName;
|
||||||
|
|
@ -25,12 +24,12 @@ public class NearbyViewHolder implements ViewHolder<Place> {
|
||||||
public void bindModel(Context context, Place place) {
|
public void bindModel(Context context, Place place) {
|
||||||
// Populate the data into the template view using the data object
|
// Populate the data into the template view using the data object
|
||||||
tvName.setText(place.name);
|
tvName.setText(place.name);
|
||||||
String description = place.description;
|
String descriptionText = place.getDescription().getText();
|
||||||
if ( description == null || description.isEmpty() || description.equals("?")) {
|
if (descriptionText.equals("?")) {
|
||||||
description = context.getString(R.string.no_description_found);
|
descriptionText = context.getString(R.string.no_description_found);
|
||||||
}
|
}
|
||||||
tvDesc.setText(description);
|
tvDesc.setText(descriptionText);
|
||||||
distance.setText(place.distance);
|
distance.setText(place.distance);
|
||||||
icon.setImageResource(ResourceUtils.getDescriptionIcon(place.description));
|
icon.setImageResource(place.getDescription().getIcon());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,13 +2,18 @@ package fr.free.nrw.commons.nearby;
|
||||||
|
|
||||||
import android.graphics.Bitmap;
|
import android.graphics.Bitmap;
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
|
import android.support.annotation.DrawableRes;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
import fr.free.nrw.commons.R;
|
||||||
import fr.free.nrw.commons.location.LatLng;
|
import fr.free.nrw.commons.location.LatLng;
|
||||||
|
|
||||||
public class Place {
|
public class Place {
|
||||||
|
|
||||||
public final String name;
|
public final String name;
|
||||||
public final String description;
|
private final Description description;
|
||||||
public final String longDescription;
|
public final String longDescription;
|
||||||
public final Uri secondaryImageUrl;
|
public final Uri secondaryImageUrl;
|
||||||
public final LatLng location;
|
public final LatLng location;
|
||||||
|
|
@ -19,7 +24,7 @@ public class Place {
|
||||||
public Sitelinks siteLinks;
|
public Sitelinks siteLinks;
|
||||||
|
|
||||||
|
|
||||||
public Place(String name, String description, String longDescription,
|
public Place(String name, Description description, String longDescription,
|
||||||
Uri secondaryImageUrl, LatLng location, Sitelinks siteLinks) {
|
Uri secondaryImageUrl, LatLng location, Sitelinks siteLinks) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
this.description = description;
|
this.description = description;
|
||||||
|
|
@ -29,6 +34,10 @@ public class Place {
|
||||||
this.siteLinks = siteLinks;
|
this.siteLinks = siteLinks;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Description getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
public void setDistance(String distance) {
|
public void setDistance(String distance) {
|
||||||
this.distance = distance;
|
this.distance = distance;
|
||||||
}
|
}
|
||||||
|
|
@ -36,7 +45,7 @@ public class Place {
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(Object o) {
|
public boolean equals(Object o) {
|
||||||
if (o instanceof Place) {
|
if (o instanceof Place) {
|
||||||
Place that = (Place)o;
|
Place that = (Place) o;
|
||||||
return this.name.equals(that.name) && this.location.equals(that.location);
|
return this.name.equals(that.name) && this.location.equals(that.location);
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -53,4 +62,68 @@ public class Place {
|
||||||
return String.format("Place(%s@%s)", name, location);
|
return String.format("Place(%s@%s)", name, location);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* See https://github.com/commons-app/apps-android-commons/issues/250
|
||||||
|
* Most common types of desc: building, house, cottage, farmhouse,
|
||||||
|
* village, civil parish, church, railway station,
|
||||||
|
* gatehouse, milestone, inn, secondary school, hotel
|
||||||
|
*
|
||||||
|
* TODO Give a more accurate class name (see issue #742).
|
||||||
|
*/
|
||||||
|
public enum Description {
|
||||||
|
|
||||||
|
BUILDING("building", R.drawable.round_icon_generic_building),
|
||||||
|
HOUSE("house", R.drawable.round_icon_house),
|
||||||
|
COTTAGE("cottage", R.drawable.round_icon_house),
|
||||||
|
FARMHOUSE("farmhouse", R.drawable.round_icon_house),
|
||||||
|
CHURCH("church", R.drawable.round_icon_church),
|
||||||
|
RAILWAY_STATION("railway station", R.drawable.round_icon_railway_station),
|
||||||
|
GATEHOUSE("gatehouse", R.drawable.round_icon_gatehouse),
|
||||||
|
MILESTONE("milestone", R.drawable.round_icon_milestone),
|
||||||
|
INN("inn", R.drawable.round_icon_house),
|
||||||
|
CITY("city", R.drawable.round_icon_city),
|
||||||
|
SECONDARY_SCHOOL("secondary school", R.drawable.round_icon_school),
|
||||||
|
EDU("edu", R.drawable.round_icon_school),
|
||||||
|
ISLE("isle", R.drawable.round_icon_island),
|
||||||
|
MOUNTAIN("mountain", R.drawable.round_icon_mountain),
|
||||||
|
AIRPORT("airport", R.drawable.round_icon_airport),
|
||||||
|
BRIDGE("bridge", R.drawable.round_icon_bridge),
|
||||||
|
ROAD("road", R.drawable.round_icon_road),
|
||||||
|
FOREST("forest", R.drawable.round_icon_forest),
|
||||||
|
PARK("park", R.drawable.round_icon_park),
|
||||||
|
RIVER("river", R.drawable.round_icon_river),
|
||||||
|
WATERFALL("waterfall", R.drawable.round_icon_waterfall),
|
||||||
|
UNKNOWN("?", R.drawable.round_icon_unknown);
|
||||||
|
|
||||||
|
private static final Map<String, Description> TEXT_TO_DESCRIPTION
|
||||||
|
= new HashMap<>(Description.values().length);
|
||||||
|
|
||||||
|
static {
|
||||||
|
for (Description description : values()) {
|
||||||
|
TEXT_TO_DESCRIPTION.put(description.text, description);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private final String text;
|
||||||
|
@DrawableRes private final int icon;
|
||||||
|
|
||||||
|
Description(String text, @DrawableRes int icon) {
|
||||||
|
this.text = text;
|
||||||
|
this.icon = icon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getText() {
|
||||||
|
return text;
|
||||||
|
}
|
||||||
|
|
||||||
|
@DrawableRes
|
||||||
|
public int getIcon() {
|
||||||
|
return icon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Description fromText(String text) {
|
||||||
|
Description description = TEXT_TO_DESCRIPTION.get(text);
|
||||||
|
return description == null ? UNKNOWN : description;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,56 +1,52 @@
|
||||||
package fr.free.nrw.commons.theme;
|
package fr.free.nrw.commons.theme;
|
||||||
|
|
||||||
import android.os.Bundle;
|
import android.content.ActivityNotFoundException;
|
||||||
|
import android.content.DialogInterface;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.support.annotation.NonNull;
|
||||||
|
import android.support.design.widget.NavigationView;
|
||||||
import android.support.v4.widget.DrawerLayout;
|
import android.support.v4.widget.DrawerLayout;
|
||||||
import android.support.v7.app.ActionBarDrawerToggle;
|
import android.support.v7.app.ActionBarDrawerToggle;
|
||||||
|
import android.support.v7.app.AlertDialog;
|
||||||
import android.support.v7.widget.Toolbar;
|
import android.support.v7.widget.Toolbar;
|
||||||
|
import android.view.MenuItem;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.RelativeLayout;
|
import android.widget.Toast;
|
||||||
|
|
||||||
import butterknife.BindView;
|
import butterknife.BindView;
|
||||||
|
import fr.free.nrw.commons.AboutActivity;
|
||||||
|
import fr.free.nrw.commons.BuildConfig;
|
||||||
|
import fr.free.nrw.commons.CommonsApplication;
|
||||||
import fr.free.nrw.commons.R;
|
import fr.free.nrw.commons.R;
|
||||||
import fr.free.nrw.commons.hamburger.HamburgerMenuContainer;
|
import fr.free.nrw.commons.WelcomeActivity;
|
||||||
import fr.free.nrw.commons.hamburger.NavigationBaseFragment;
|
import fr.free.nrw.commons.auth.LoginActivity;
|
||||||
import fr.free.nrw.commons.utils.FragmentUtils;
|
import fr.free.nrw.commons.contributions.ContributionsActivity;
|
||||||
|
import fr.free.nrw.commons.nearby.NearbyActivity;
|
||||||
|
import fr.free.nrw.commons.settings.SettingsActivity;
|
||||||
|
|
||||||
import static android.support.v4.view.GravityCompat.START;
|
public class NavigationBaseActivity extends BaseActivity
|
||||||
|
implements NavigationView.OnNavigationItemSelectedListener {
|
||||||
|
|
||||||
public class NavigationBaseActivity extends BaseActivity implements HamburgerMenuContainer {
|
|
||||||
@BindView(R.id.toolbar)
|
@BindView(R.id.toolbar)
|
||||||
Toolbar toolbar;
|
Toolbar toolbar;
|
||||||
|
|
||||||
|
@BindView(R.id.navigation_view)
|
||||||
|
NavigationView navigationView;
|
||||||
|
|
||||||
@BindView(R.id.drawer_layout)
|
@BindView(R.id.drawer_layout)
|
||||||
DrawerLayout drawerLayout;
|
DrawerLayout drawerLayout;
|
||||||
|
|
||||||
@BindView(R.id.drawer_pane)
|
|
||||||
RelativeLayout drawerPane;
|
|
||||||
|
|
||||||
private ActionBarDrawerToggle toggle;
|
private ActionBarDrawerToggle toggle;
|
||||||
|
|
||||||
@Override
|
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
|
||||||
super.onCreate(savedInstanceState);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void initDrawer() {
|
public void initDrawer() {
|
||||||
initSubviews();
|
navigationView.setNavigationItemSelectedListener(this);
|
||||||
NavigationBaseFragment baseFragment = new NavigationBaseFragment();
|
|
||||||
baseFragment.setDrawerLayout(drawerLayout, drawerPane);
|
|
||||||
FragmentUtils.addAndCommitFragmentWithImmediateExecution(getSupportFragmentManager(),
|
|
||||||
R.id.drawer_fragment,
|
|
||||||
baseFragment);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void initSubviews() {
|
|
||||||
setSupportActionBar(toolbar);
|
setSupportActionBar(toolbar);
|
||||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
||||||
toggle = new ActionBarDrawerToggle(this,
|
toggle = new ActionBarDrawerToggle(this, drawerLayout, toolbar,
|
||||||
drawerLayout,
|
R.string.navigation_drawer_open, R.string.navigation_drawer_close);
|
||||||
toolbar,
|
drawerLayout.addDrawerListener(toggle);
|
||||||
R.string.navigation_drawer_open,
|
|
||||||
R.string.navigation_drawer_close);
|
|
||||||
drawerLayout.setDrawerListener(toggle);
|
|
||||||
toggle.setDrawerIndicatorEnabled(true);
|
toggle.setDrawerIndicatorEnabled(true);
|
||||||
toggle.syncState();
|
toggle.syncState();
|
||||||
setDrawerPaneWidth();
|
setDrawerPaneWidth();
|
||||||
|
|
@ -74,28 +70,77 @@ public class NavigationBaseActivity extends BaseActivity implements HamburgerMen
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setDrawerPaneWidth() {
|
private void setDrawerPaneWidth() {
|
||||||
ViewGroup.LayoutParams params = drawerPane.getLayoutParams();
|
ViewGroup.LayoutParams params = navigationView.getLayoutParams();
|
||||||
// set width to lowerBound of 80% of the screen size
|
// set width to lowerBound of 80% of the screen size
|
||||||
params.width = (getResources().getDisplayMetrics().widthPixels * 70) / 100;
|
params.width = (getResources().getDisplayMetrics().widthPixels * 70) / 100;
|
||||||
drawerPane.setLayoutParams(params);
|
navigationView.setLayoutParams(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setDrawerListener(ActionBarDrawerToggle listener) {
|
public boolean onNavigationItemSelected(@NonNull final MenuItem item) {
|
||||||
drawerLayout.setDrawerListener(listener);
|
switch (item.getItemId()) {
|
||||||
}
|
case R.id.action_home:
|
||||||
|
drawerLayout.closeDrawer(navigationView);
|
||||||
@Override
|
ContributionsActivity.startYourself(this);
|
||||||
public void toggleDrawer() {
|
return true;
|
||||||
if (drawerLayout.isDrawerVisible(START)) {
|
case R.id.action_nearby:
|
||||||
drawerLayout.closeDrawer(START);
|
drawerLayout.closeDrawer(navigationView);
|
||||||
} else {
|
NearbyActivity.startYourself(this);
|
||||||
drawerLayout.openDrawer(START);
|
return true;
|
||||||
|
case R.id.action_about:
|
||||||
|
drawerLayout.closeDrawer(navigationView);
|
||||||
|
AboutActivity.startYourself(this);
|
||||||
|
return true;
|
||||||
|
case R.id.action_settings:
|
||||||
|
drawerLayout.closeDrawer(navigationView);
|
||||||
|
SettingsActivity.startYourself(this);
|
||||||
|
return true;
|
||||||
|
case R.id.action_introduction:
|
||||||
|
drawerLayout.closeDrawer(navigationView);
|
||||||
|
WelcomeActivity.startYourself(this);
|
||||||
|
return true;
|
||||||
|
case R.id.action_feedback:
|
||||||
|
drawerLayout.closeDrawer(navigationView);
|
||||||
|
Intent feedbackIntent = new Intent(Intent.ACTION_SEND);
|
||||||
|
feedbackIntent.setType("message/rfc822");
|
||||||
|
feedbackIntent.putExtra(Intent.EXTRA_EMAIL,
|
||||||
|
new String[]{CommonsApplication.FEEDBACK_EMAIL});
|
||||||
|
feedbackIntent.putExtra(Intent.EXTRA_SUBJECT,
|
||||||
|
String.format(CommonsApplication.FEEDBACK_EMAIL_SUBJECT,
|
||||||
|
BuildConfig.VERSION_NAME));
|
||||||
|
try {
|
||||||
|
startActivity(feedbackIntent);
|
||||||
|
} catch (ActivityNotFoundException e) {
|
||||||
|
Toast.makeText(this, R.string.no_email_client, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
case R.id.action_logout:
|
||||||
|
new AlertDialog.Builder(this)
|
||||||
|
.setMessage(R.string.logout_verification)
|
||||||
|
.setCancelable(false)
|
||||||
|
.setPositiveButton(R.string.yes, new DialogInterface.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
|
((CommonsApplication) getApplicationContext())
|
||||||
|
.clearApplicationData(NavigationBaseActivity.this);
|
||||||
|
Intent nearbyIntent = new Intent(
|
||||||
|
NavigationBaseActivity.this, LoginActivity.class);
|
||||||
|
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
||||||
|
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||||
|
startActivity(nearbyIntent);
|
||||||
|
finish();
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.setNegativeButton(R.string.no, new DialogInterface.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
|
dialog.cancel();
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.show();
|
||||||
|
return true;
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean isDrawerVisible() {
|
|
||||||
return drawerLayout.isDrawerVisible(START);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,89 +0,0 @@
|
||||||
package fr.free.nrw.commons.utils;
|
|
||||||
|
|
||||||
import android.support.annotation.DrawableRes;
|
|
||||||
|
|
||||||
import fr.free.nrw.commons.R;
|
|
||||||
|
|
||||||
public class ResourceUtils {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* See https://github.com/commons-app/apps-android-commons/issues/250
|
|
||||||
* Most common types of desc: building, house, cottage, farmhouse,
|
|
||||||
* village, civil parish, church, railway station,
|
|
||||||
* gatehouse, milestone, inn, secondary school, hotel
|
|
||||||
* @param description Place description
|
|
||||||
* @return icon res id
|
|
||||||
*/
|
|
||||||
@DrawableRes
|
|
||||||
public static int getDescriptionIcon(String description) {
|
|
||||||
int resourceId;
|
|
||||||
switch (description) {
|
|
||||||
case "building":
|
|
||||||
resourceId = R.drawable.round_icon_generic_building;
|
|
||||||
break;
|
|
||||||
case "house":
|
|
||||||
resourceId = R.drawable.round_icon_house;
|
|
||||||
break;
|
|
||||||
case "cottage":
|
|
||||||
resourceId = R.drawable.round_icon_house;
|
|
||||||
break;
|
|
||||||
case "farmhouse":
|
|
||||||
resourceId = R.drawable.round_icon_house;
|
|
||||||
break;
|
|
||||||
case "church":
|
|
||||||
resourceId = R.drawable.round_icon_church;
|
|
||||||
break;
|
|
||||||
case "railway station":
|
|
||||||
resourceId = R.drawable.round_icon_railway_station;
|
|
||||||
break;
|
|
||||||
case "gatehouse":
|
|
||||||
resourceId = R.drawable.round_icon_gatehouse;
|
|
||||||
break;
|
|
||||||
case "milestone":
|
|
||||||
resourceId = R.drawable.round_icon_milestone;
|
|
||||||
break;
|
|
||||||
case "inn":
|
|
||||||
resourceId = R.drawable.round_icon_house;
|
|
||||||
break;
|
|
||||||
case "city":
|
|
||||||
resourceId = R.drawable.round_icon_city;
|
|
||||||
break;
|
|
||||||
case "secondary school":
|
|
||||||
resourceId = R.drawable.round_icon_school;
|
|
||||||
break;
|
|
||||||
case "edu":
|
|
||||||
resourceId = R.drawable.round_icon_school;
|
|
||||||
break;
|
|
||||||
case "isle":
|
|
||||||
resourceId = R.drawable.round_icon_island;
|
|
||||||
break;
|
|
||||||
case "mountain":
|
|
||||||
resourceId = R.drawable.round_icon_mountain;
|
|
||||||
break;
|
|
||||||
case "airport":
|
|
||||||
resourceId = R.drawable.round_icon_airport;
|
|
||||||
break;
|
|
||||||
case "bridge":
|
|
||||||
resourceId = R.drawable.round_icon_bridge;
|
|
||||||
break;
|
|
||||||
case "road":
|
|
||||||
resourceId = R.drawable.round_icon_road;
|
|
||||||
break;
|
|
||||||
case "forest":
|
|
||||||
resourceId = R.drawable.round_icon_forest;
|
|
||||||
break;
|
|
||||||
case "park":
|
|
||||||
resourceId = R.drawable.round_icon_park;
|
|
||||||
break;
|
|
||||||
case "river":
|
|
||||||
resourceId = R.drawable.round_icon_river;
|
|
||||||
break;
|
|
||||||
case "waterfall":
|
|
||||||
resourceId = R.drawable.round_icon_waterfall;
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
resourceId = R.drawable.round_icon_unknown;
|
|
||||||
}
|
|
||||||
return resourceId;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
||||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
|
||||||
|
|
||||||
<item android:state_pressed="true">
|
|
||||||
<shape android:shape="rectangle">
|
|
||||||
<solid android:color="@color/hamburger_item_pressed_color" />
|
|
||||||
</shape>
|
|
||||||
</item>
|
|
||||||
|
|
||||||
<item android:state_enabled="true">
|
|
||||||
<shape android:shape="rectangle">
|
|
||||||
<solid android:color="@android:color/transparent" />
|
|
||||||
</shape>
|
|
||||||
</item>
|
|
||||||
|
|
||||||
</selector>
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/drawer_layout"
|
android:id="@+id/drawer_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
@ -89,17 +90,12 @@
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer"/>
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/drawer_layout"
|
android:id="@+id/drawer_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
@ -32,17 +33,12 @@
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer"/>
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/drawer_layout"
|
android:id="@+id/drawer_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
@ -22,17 +23,12 @@
|
||||||
android:orientation="vertical"></FrameLayout>
|
android:orientation="vertical"></FrameLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer" />
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/drawer_layout"
|
android:id="@+id/drawer_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
@ -35,17 +36,12 @@
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer"/>
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/drawer_layout"
|
android:id="@+id/drawer_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
@ -24,17 +25,12 @@
|
||||||
android:layout_below="@id/toolbar"/>
|
android:layout_below="@id/toolbar"/>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer"/>
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
|
|
@ -36,17 +36,12 @@
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<RelativeLayout
|
<android.support.design.widget.NavigationView
|
||||||
android:id="@+id/drawer_pane"
|
android:id="@+id/navigation_view"
|
||||||
android:layout_width="320dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="start"
|
||||||
android:background="@android:color/white">
|
app:headerLayout="@layout/drawer_header"
|
||||||
|
app:menu="@menu/drawer" />
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/drawer_fragment"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</android.support.v4.widget.DrawerLayout>
|
</android.support.v4.widget.DrawerLayout>
|
||||||
8
app/src/main/res/layout/drawer_header.xml
Normal file
8
app/src/main/res/layout/drawer_header.xml
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ImageView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:id="@+id/pictureOfTheDay"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="172dp"
|
||||||
|
android:background="@android:color/darker_gray"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:src="@drawable/commons_logo_large"/>
|
||||||
|
|
@ -1,200 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<ScrollView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical">
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:background="@android:color/darker_gray">
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/pictureOfTheDay"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_marginTop="12dp"
|
|
||||||
android:layout_marginBottom="12dp"
|
|
||||||
android:layout_height="140dp" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<View
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="0.5dp"
|
|
||||||
android:background="@android:color/black"/>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/upload_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_home_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_home"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/nearby_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_location_on_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_nearby"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/about_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_info_outline_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_about"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/settings_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_settings_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_settings"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/introduction_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_info_outline_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_info"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/feedback_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_feedback_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_feedback"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/logout_item"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="52dp"
|
|
||||||
android:background="@drawable/hamburger_item_bg"
|
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="20dp"
|
|
||||||
android:src="@drawable/ic_exit_to_app_black_24dp" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="12dp"
|
|
||||||
android:text="@string/navigation_item_logout"
|
|
||||||
android:letterSpacing="0.02"
|
|
||||||
android:textColor="@color/main_background_dark"
|
|
||||||
android:textSize="@dimen/hamburger_menu_item" />
|
|
||||||
</LinearLayout>
|
|
||||||
</LinearLayout>
|
|
||||||
</ScrollView>
|
|
||||||
</LinearLayout>
|
|
||||||
38
app/src/main/res/menu/drawer.xml
Normal file
38
app/src/main/res/menu/drawer.xml
Normal file
|
|
@ -0,0 +1,38 @@
|
||||||
|
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_home"
|
||||||
|
android:icon="@drawable/ic_home_black_24dp"
|
||||||
|
android:title="@string/navigation_item_home"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_nearby"
|
||||||
|
android:icon="@drawable/ic_location_on_black_24dp"
|
||||||
|
android:title="@string/navigation_item_nearby"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_about"
|
||||||
|
android:icon="@drawable/ic_info_outline_black_24dp"
|
||||||
|
android:title="@string/navigation_item_about"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_settings"
|
||||||
|
android:icon="@drawable/ic_settings_black_24dp"
|
||||||
|
android:title="@string/navigation_item_settings"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_introduction"
|
||||||
|
android:icon="@drawable/ic_info_outline_black_24dp"
|
||||||
|
android:title="@string/navigation_item_info"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_feedback"
|
||||||
|
android:icon="@drawable/ic_feedback_black_24dp"
|
||||||
|
android:title="@string/navigation_item_feedback"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_logout"
|
||||||
|
android:icon="@drawable/ic_exit_to_app_black_24dp"
|
||||||
|
android:title="@string/navigation_item_logout"/>
|
||||||
|
|
||||||
|
</menu>
|
||||||
7
app/src/main/res/values-b+roa+tara/error.xml
Normal file
7
app/src/main/res/values-b+roa+tara/error.xml
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<resources>
|
||||||
|
<string name="crash_dialog_title">Commons ha sckattate</string>
|
||||||
|
<string name="crash_dialog_text">Mudu. Quacchecose ha sciute male!</string>
|
||||||
|
<string name="crash_dialog_comment_prompt">Fanne sapé ce ste facive e mannale pe email. Quiste ne pò dà \'na màne a resolvere \'u probbleme!</string>
|
||||||
|
<string name="crash_dialog_ok_toast">Grazie \'mbà</string>
|
||||||
|
</resources>
|
||||||
|
|
@ -20,10 +20,10 @@
|
||||||
<string name="upload_progress_notification_title_finishing">%1$s のアップロードを完了中</string>
|
<string name="upload_progress_notification_title_finishing">%1$s のアップロードを完了中</string>
|
||||||
<string name="upload_failed_notification_title">%1$s のアップロードに失敗しました</string>
|
<string name="upload_failed_notification_title">%1$s のアップロードに失敗しました</string>
|
||||||
<string name="upload_failed_notification_subtitle">閲覧するにはタップしてください</string>
|
<string name="upload_failed_notification_subtitle">閲覧するにはタップしてください</string>
|
||||||
<plurals name="uploads_pending_notification_indicator" fuzzy="true">
|
<plurals name="uploads_pending_notification_indicator">
|
||||||
<item quantity="other">%d 件のファイルをアップロード中</item>
|
<item quantity="other">%d 件のファイルをアップロード中</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
<string name="title_activity_contributions" fuzzy="true">自分のアップロード</string>
|
<string name="title_activity_contributions">自分の最近のアップロードファイル</string>
|
||||||
<string name="contribution_state_queued">順番待ち中</string>
|
<string name="contribution_state_queued">順番待ち中</string>
|
||||||
<string name="contribution_state_failed">失敗しました</string>
|
<string name="contribution_state_failed">失敗しました</string>
|
||||||
<string name="contribution_state_in_progress">%1$d%% 完了</string>
|
<string name="contribution_state_in_progress">%1$d%% 完了</string>
|
||||||
|
|
@ -49,14 +49,14 @@
|
||||||
<string name="categories_search_text_hint">検索するカテゴリ</string>
|
<string name="categories_search_text_hint">検索するカテゴリ</string>
|
||||||
<string name="menu_save_categories">保存</string>
|
<string name="menu_save_categories">保存</string>
|
||||||
<string name="refresh_button">更新</string>
|
<string name="refresh_button">更新</string>
|
||||||
<plurals name="contributions_subtitle" fuzzy="true">
|
<plurals name="contributions_subtitle">
|
||||||
<item quantity="zero">アップロードしたファイルはありません</item>
|
<item quantity="zero">\@string/contributions_subtitle_zero</item>
|
||||||
<item quantity="other">%d 件のアップロード</item>
|
<item quantity="other">%d 件のアップロード</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
<plurals name="starting_multiple_uploads" fuzzy="true">
|
<plurals name="starting_multiple_uploads">
|
||||||
<item quantity="other">%d 件のアップロードを開始中</item>
|
<item quantity="other">%d 件のアップロードを開始中</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
<plurals name="multiple_uploads_title" fuzzy="true">
|
<plurals name="multiple_uploads_title">
|
||||||
<item quantity="other">%d 件のアップロード</item>
|
<item quantity="other">%d 件のアップロード</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
<string name="categories_not_found">%1$s に一致するカテゴリが見つかりません</string>
|
<string name="categories_not_found">%1$s に一致するカテゴリが見つかりません</string>
|
||||||
|
|
@ -70,7 +70,7 @@
|
||||||
<string name="about_license"><a href=\"https://github.com/commons-app/apps-android-commons/blob/master/COPYING\">Apache ライセンス v2</a> のもとで公開されているオープン ソース ソフトウェアです。Wikimedia Commons ならびにそのロゴはウィキメディア財団の商標であり、ウィキメディア財団の許可により使用しています。このサイトはウィキメディア財団の公認3でも提携先でもありません。</string>
|
<string name="about_license"><a href=\"https://github.com/commons-app/apps-android-commons/blob/master/COPYING\">Apache ライセンス v2</a> のもとで公開されているオープン ソース ソフトウェアです。Wikimedia Commons ならびにそのロゴはウィキメディア財団の商標であり、ウィキメディア財団の許可により使用しています。このサイトはウィキメディア財団の公認3でも提携先でもありません。</string>
|
||||||
<string name="about_improve">ソースは <a href=\"https://github.com/commons-app/apps-android-commons\">GitHub</a> にあります。バグとアイディアは <a href=\"https://github.com/commons-app/apps-android-commons/issues\">Github</a> へ。</string>
|
<string name="about_improve">ソースは <a href=\"https://github.com/commons-app/apps-android-commons\">GitHub</a> にあります。バグとアイディアは <a href=\"https://github.com/commons-app/apps-android-commons/issues\">Github</a> へ。</string>
|
||||||
<string name="about_privacy_policy"><a href=\"https://wikimediafoundation.org/wiki/プライバシー・ポリシー\">プライバシー・ポリシー</a></string>
|
<string name="about_privacy_policy"><a href=\"https://wikimediafoundation.org/wiki/プライバシー・ポリシー\">プライバシー・ポリシー</a></string>
|
||||||
<string name="about_credits" fuzzy="true"><a href=\"https://github.com/commons-app/apps-android-commons/blob/master/CREDITS\">CREDITS</a></string>
|
<string name="about_credits"><a href=\"https://github.com/commons-app/apps-android-commons/blob/master/CREDITS\">クレジット</a></string>
|
||||||
<string name="title_activity_about">このアプリについて</string>
|
<string name="title_activity_about">このアプリについて</string>
|
||||||
<string name="menu_feedback">フィードバックをメールで送信</string>
|
<string name="menu_feedback">フィードバックをメールで送信</string>
|
||||||
<string name="no_email_client">メールアプリケーションが見つかりません</string>
|
<string name="no_email_client">メールアプリケーションが見つかりません</string>
|
||||||
|
|
@ -139,8 +139,30 @@
|
||||||
<string name="media_detail_media_title">メディアのタイトル</string>
|
<string name="media_detail_media_title">メディアのタイトル</string>
|
||||||
<string name="media_detail_description">記述</string>
|
<string name="media_detail_description">記述</string>
|
||||||
<string name="media_detail_description_explanation">ここにメディアの説明が入ります。かなり長文になる場合には数行にわたることがあります。それでも見栄えがよいと願っています。</string>
|
<string name="media_detail_description_explanation">ここにメディアの説明が入ります。かなり長文になる場合には数行にわたることがあります。それでも見栄えがよいと願っています。</string>
|
||||||
|
<string name="media_detail_uploaded_date">アップロード日時</string>
|
||||||
<string name="become_a_tester_title">ベータ版を使ってみましょう!</string>
|
<string name="become_a_tester_title">ベータ版を使ってみましょう!</string>
|
||||||
<string name="become_a_tester_description">Google Playのベータ版チャンネルにオプトインして、新機能やバグ修正プログラムに早期にアクセス</string>
|
<string name="become_a_tester_description">Google Playのベータ版チャンネルにオプトインして、新機能やバグ修正プログラムに早期にアクセス</string>
|
||||||
<string name="use_wikidata">ウィキデータを使用してください</string>
|
<string name="use_wikidata">ウィキデータを使用してください</string>
|
||||||
<string name="use_wikidata_summary">(警告:これを無効にすると、モバイルデータを大量に消費する可能性があります)</string>
|
<string name="use_wikidata_summary">(警告:これを無効にすると、モバイルデータを大量に消費する可能性があります)</string>
|
||||||
|
<string name="number_of_uploads">最近のアップロードファイルに表示する最大件数</string>
|
||||||
|
<string name="background_image">背景画像</string>
|
||||||
|
<string name="no_image_found">画像がありません</string>
|
||||||
|
<string name="upload_image">画像をアップロード</string>
|
||||||
|
<string name="welcome_image_mount_zao">蔵王連峰</string>
|
||||||
|
<string name="welcome_image_llamas">リャマ</string>
|
||||||
|
<string name="welcome_image_rainbow_bridge">レインボーブリッジ</string>
|
||||||
|
<string name="welcome_image_tulip">チューリップ</string>
|
||||||
|
<string name="welcome_image_welcome_wikipedia">ウィキペディアへようこそ</string>
|
||||||
|
<string name="cancel">キャンセル</string>
|
||||||
|
<string name="navigation_drawer_open">開く</string>
|
||||||
|
<string name="navigation_drawer_close">閉じる</string>
|
||||||
|
<string name="navigation_item_home">ホーム</string>
|
||||||
|
<string name="navigation_item_upload">アップロード</string>
|
||||||
|
<string name="navigation_item_about">このアプリについて</string>
|
||||||
|
<string name="navigation_item_settings">設定</string>
|
||||||
|
<string name="navigation_item_feedback">フィードバック</string>
|
||||||
|
<string name="navigation_item_logout">ログアウト</string>
|
||||||
|
<string name="navigation_item_info">チュートリアル</string>
|
||||||
|
<string name="no_description_found">説明がありません</string>
|
||||||
|
<string name="nearby_info_menu_wikidata_article">ウィキデータ項目</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@
|
||||||
<item quantity="one">Przesyłanie %d pliku</item>
|
<item quantity="one">Przesyłanie %d pliku</item>
|
||||||
<item quantity="other">Przesyłanie %d plików</item>
|
<item quantity="other">Przesyłanie %d plików</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
<string name="title_activity_contributions" fuzzy="true">Wysłane przeze mnie pliki</string>
|
<string name="title_activity_contributions">Niedawno przesłane</string>
|
||||||
<string name="contribution_state_queued">W kolejce</string>
|
<string name="contribution_state_queued">W kolejce</string>
|
||||||
<string name="contribution_state_failed">Porażka</string>
|
<string name="contribution_state_failed">Porażka</string>
|
||||||
<string name="contribution_state_in_progress">%1$d%% zakończone</string>
|
<string name="contribution_state_in_progress">%1$d%% zakończone</string>
|
||||||
|
|
|
||||||
|
|
@ -101,7 +101,7 @@
|
||||||
<string name="welcome_image_llamas">An animal. See [[:d:Q42569|Wikidata item Q42569]] for a list of possible translations.</string>
|
<string name="welcome_image_llamas">An animal. See [[:d:Q42569|Wikidata item Q42569]] for a list of possible translations.</string>
|
||||||
<string name="welcome_image_rainbow_bridge">A bridge in Japan. See [[:d:Q1046736|Wikidata item Q1046736]] for a list of possible translations.</string>
|
<string name="welcome_image_rainbow_bridge">A bridge in Japan. See [[:d:Q1046736|Wikidata item Q1046736]] for a list of possible translations.</string>
|
||||||
<string name="welcome_image_tulip">A flower. See [[:d:Q93201|Wikidata item Q93201]] for a list of possible translations.</string>
|
<string name="welcome_image_tulip">A flower. See [[:d:Q93201|Wikidata item Q93201]] for a list of possible translations.</string>
|
||||||
<string name="welcome_image_welcome_wikipedia">Witaj na Wikipedii</string>
|
<string name="welcome_image_welcome_wikipedia">Welcome Wikipedia</string>
|
||||||
<string name="welcome_image_sydney_opera_house">A building in the city of Sydney. See [[:d:Q45178|Wikidata item Q45178]] for a list of possible translations.</string>
|
<string name="welcome_image_sydney_opera_house">A building in the city of Sydney. See [[:d:Q45178|Wikidata item Q45178]] for a list of possible translations.</string>
|
||||||
<string name="cancel">{{Identical|Cancel}}</string>
|
<string name="cancel">{{Identical|Cancel}}</string>
|
||||||
<string name="navigation_drawer_open">{{Identical|Open}}</string>
|
<string name="navigation_drawer_open">{{Identical|Open}}</string>
|
||||||
|
|
|
||||||
|
|
@ -21,6 +21,4 @@
|
||||||
<color name="button_background_light">#B0000000</color>
|
<color name="button_background_light">#B0000000</color>
|
||||||
<color name="upload_overlay_background_dark">#77000000</color>
|
<color name="upload_overlay_background_dark">#77000000</color>
|
||||||
<color name="upload_overlay_background_light">#44000000</color>
|
<color name="upload_overlay_background_light">#44000000</color>
|
||||||
|
|
||||||
<color name="hamburger_item_pressed_color">#f5f5f5</color>
|
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,5 @@
|
||||||
<dimen name="tiny_margin">4dp</dimen>
|
<dimen name="tiny_margin">4dp</dimen>
|
||||||
<dimen name="small_margin">8dp</dimen>
|
<dimen name="small_margin">8dp</dimen>
|
||||||
<dimen name="bottom_peak_height">240dp</dimen>
|
<dimen name="bottom_peak_height">240dp</dimen>
|
||||||
<dimen name="hamburger_menu_item">18sp</dimen>
|
|
||||||
<dimen name="overflow_button_dimen">48dp</dimen>
|
<dimen name="overflow_button_dimen">48dp</dimen>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue