Translations

This commit is contained in:
serso
2016-05-16 10:07:10 +02:00
parent 947516e905
commit f21fdf0d07
30 changed files with 33 additions and 139 deletions

View File

@@ -37,13 +37,13 @@ import org.solovyev.android.calculator.calculations.ConversionFailedEvent;
import org.solovyev.android.calculator.calculations.ConversionFinishedEvent;
import org.solovyev.android.calculator.errors.FixableErrorsActivity;
import dagger.Lazy;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import javax.inject.Inject;
import javax.inject.Singleton;
import dagger.Lazy;
@Singleton
public class Display {
@@ -80,8 +80,7 @@ public class Display {
return;
}
clipboard.get().setText(state.text);
notifier.get().showMessage(
CalculatorMessage.newInfoMessage(CalculatorMessages.result_copied));
notifier.get().showMessage(R.string.cpp_text_copied);
}
@Subscribe

View File

@@ -38,7 +38,7 @@ public enum FragmentTab {
history(RecentHistoryFragment.class, R.string.cpp_history_tab_recent),
saved_history(SavedHistoryFragment.class, R.string.cpp_history_tab_saved),
variables(VariablesFragment.class, R.string.c_vars),
variables(VariablesFragment.class, R.string.c_vars_and_constants),
functions(FunctionsFragment.class, R.string.c_functions),
operators(OperatorsFragment.class, R.string.c_operators),
about(AboutFragment.class, R.string.cpp_about),

View File

@@ -389,7 +389,7 @@ public class ConverterFragment extends BaseDialogFragment
break;
case DialogInterface.BUTTON_NEUTRAL:
clipboard.setText(text);
Toast.makeText(getActivity(), getString(R.string.c_result_copied),
Toast.makeText(getActivity(), getString(R.string.cpp_text_copied),
Toast.LENGTH_SHORT).show();
break;
}

View File

@@ -44,12 +44,19 @@ import android.view.inputmethod.InputMethodManager;
import android.widget.Button;
import android.widget.EditText;
import android.widget.PopupWindow;
import butterknife.Bind;
import butterknife.ButterKnife;
import dagger.Lazy;
import jscl.math.function.IConstant;
import org.solovyev.android.Check;
import org.solovyev.android.calculator.*;
import org.solovyev.android.calculator.App;
import org.solovyev.android.calculator.AppComponent;
import org.solovyev.android.calculator.BaseDialogFragment;
import org.solovyev.android.calculator.Calculator;
import org.solovyev.android.calculator.Engine;
import org.solovyev.android.calculator.Keyboard;
import org.solovyev.android.calculator.PreparedExpression;
import org.solovyev.android.calculator.R;
import org.solovyev.android.calculator.RemovalConfirmationDialog;
import org.solovyev.android.calculator.ToJsclTextProcessor;
import org.solovyev.android.calculator.VariablesRegistry;
import org.solovyev.android.calculator.functions.FunctionsRegistry;
import org.solovyev.android.calculator.keyboard.FloatingKeyboard;
import org.solovyev.android.calculator.keyboard.FloatingKeyboardWindow;
@@ -58,11 +65,17 @@ import org.solovyev.android.calculator.view.EditTextCompat;
import org.solovyev.android.text.method.NumberInputFilter;
import org.solovyev.common.text.Strings;
import java.util.Arrays;
import java.util.List;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import javax.inject.Inject;
import java.util.Arrays;
import java.util.List;
import butterknife.Bind;
import butterknife.ButterKnife;
import dagger.Lazy;
import jscl.math.function.IConstant;
import static org.solovyev.android.calculator.variables.CppVariable.NO_ID;
@@ -253,7 +266,7 @@ public class EditVariableFragment extends BaseDialogFragment implements View.OnF
private boolean validateName() {
final String name = nameView.getText().toString();
if (!Engine.isValidName(name)) {
setError(nameLabel, getString(R.string.c_name_is_not_valid));
setError(nameLabel, getString(R.string.cpp_name_contains_invalid_characters));
return false;
}
for (int i = 0; i < name.length(); i++) {