Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
OLAT CI-CD Testing Project
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lars Oliver Dam
OLAT CI-CD Testing Project
Commits
6bb0e707
Commit
6bb0e707
authored
12 years ago
by
gnaegi
Browse files
Options
Downloads
Patches
Plain Diff
OO-391 allow changeing of languages in the translation tool
parent
3e9683fa
No related branches found
Branches containing commit
Tags
OpenOLAT_8.2.0beta
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/main/java/org/olat/core/util/i18n/ui/TranslationToolStartCrumbController.java
+3
-10
3 additions, 10 deletions
...ore/util/i18n/ui/TranslationToolStartCrumbController.java
with
3 additions
and
10 deletions
src/main/java/org/olat/core/util/i18n/ui/TranslationToolStartCrumbController.java
+
3
−
10
View file @
6bb0e707
...
...
@@ -179,7 +179,7 @@ class TranslationToolStartCrumbController extends CrumbFormBasicController {
ArrayHelper
.
sort
(
referencelangKeys
,
referenceLangValues
,
false
,
true
,
false
);
// Build css classes for reference languages
String
[]
referenceLangCssClasses
=
i18nMgr
.
createLanguageFlagsCssClasses
(
referencelangKeys
,
"b_with_small_icon_left"
);
//
fxdiff: FXOLAT-213
Use first reference locale as default
// Use first reference locale as default
referenceLocale
=
i18nMgr
.
getLocaleOrNull
(
referenceLangs
.
get
(
0
));
// Override with user preset
Preferences
guiPrefs
=
usess
.
getGuiPreferences
();
...
...
@@ -201,15 +201,8 @@ class TranslationToolStartCrumbController extends CrumbFormBasicController {
// Use all enabled languages in customizing mode
translatableKeys
=
I18nModule
.
getOverlayLanguageKeys
();
}
else
{
// Since 6.2 the user can only translate the language he has set in his preferences
translatableKeys
=
new
HashSet
<
String
>();
if
(
I18nModule
.
getTranslatableLanguageKeys
().
contains
(
i18nMgr
.
getLocaleKey
(
getLocale
()))){
translatableKeys
.
add
(
i18nMgr
.
getLocaleKey
(
getLocale
()));
}
else
{
// ups, user language is not translatable, give user choice to
// select one of the translatable languages
translatableKeys
=
I18nModule
.
getTranslatableLanguageKeys
();
}
// Allow translators to also translate other languages if they really desire. Show all languages.
translatableKeys
=
I18nModule
.
getTranslatableLanguageKeys
();
}
String
[]
targetlangKeys
=
ArrayHelper
.
toArray
(
translatableKeys
);
String
[]
targetLangValues
=
new
String
[
targetlangKeys
.
length
];
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment