Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 85df6415 authored by kaiyiz's avatar kaiyiz Committed by emancebo
Browse files

Gallery2: Fix the string can't be translated in Gallery2.

The string is defined in FilterDrawRepresentation.java with English.

Extract this string into source.xml file and get it by getString().

CR-fixed: 623893

Change-Id: Ied7afc964555cfd752af306742be69eba4a41349
parent b4a96363
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@ public class GalleryAppImpl extends Application implements GalleryApp {

    private static final String DOWNLOAD_FOLDER = "download";
    private static final long DOWNLOAD_CAPACITY = 64 * 1024 * 1024; // 64M
    private static GalleryAppImpl sGalleryAppImpl;

    private ImageCacheService mImageCacheService;
    private Object mLock = new Object();
@@ -51,6 +52,7 @@ public class GalleryAppImpl extends Application implements GalleryApp {
        WidgetUtils.initialize(this);
        PicasaSource.initialize(this);
        UsageStatistics.initialize(this);
        sGalleryAppImpl = this;
    }

    @Override
@@ -58,6 +60,10 @@ public class GalleryAppImpl extends Application implements GalleryApp {
        return this;
    }

    public static Context getContext() {
        return sGalleryAppImpl;
    }

    @Override
    public synchronized DataManager getDataManager() {
        if (mDataManager == null) {
+4 −2
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@

package com.android.gallery3d.filtershow.filters;

import android.content.res.Resources;
import android.graphics.Color;
import android.graphics.Path;
import android.graphics.PathMeasure;
@@ -23,6 +24,7 @@ import android.util.JsonReader;
import android.util.JsonWriter;
import android.util.Log;

import com.android.gallery3d.app.GalleryAppImpl;
import com.android.gallery3d.R;
import com.android.gallery3d.filtershow.controller.BasicParameterInt;
import com.android.gallery3d.filtershow.controller.BasicParameterStyle;
@@ -158,9 +160,9 @@ public class FilterDrawRepresentation extends FilterRepresentation {
    private StrokeData mCurrent; // used in the currently drawing style

    public FilterDrawRepresentation() {
        super("Draw");
        super(GalleryAppImpl.getContext().getString(R.string.imageDraw));
        setFilterClass(ImageFilterDraw.class);
        setSerializationName("DRAW");
        setSerializationName(GalleryAppImpl.getContext().getString(R.string.imageDraw));
        setFilterType(FilterRepresentation.TYPE_VIGNETTE);
        setTextId(R.string.imageDraw);
        setEditorId(EditorDraw.ID);