Skip to content

Commit 009e3cb

Browse files
committed
Localization technology final steps.
1 parent ac41f45 commit 009e3cb

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

source/website/index.js

+8-2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { SetEventHandler, HandleEvent } from './eventhandler.js';
55
import { PluginType, RegisterPlugin } from './pluginregistry.js';
66
import { ButtonDialog, ProgressDialog } from './dialog.js';
77
import { ShowMessageDialog } from './dialogs.js';
8+
import { Loc } from '../engine/core/localization.js';
89

910
import * as Engine from '../engine/main.js';
1011
export { Engine };
@@ -25,7 +26,8 @@ export const UI = {
2526
ButtonDialog,
2627
ProgressDialog,
2728
ShowMessageDialog,
28-
HandleEvent
29+
HandleEvent,
30+
Loc
2931
};
3032

3133
export function SetWebsiteEventHandler (eventHandler)
@@ -46,8 +48,12 @@ export function RegisterToolbarPlugin (plugin)
4648
export function StartWebsite (externalLibLocation)
4749
{
4850
SetExternalLibLocation (externalLibLocation);
51+
4952
window.addEventListener ('load', () => {
50-
let website = new Website ({
53+
document.getElementById ('intro_dragdrop_text').innerHTML = Loc ('Drag and drop 3D models here.');
54+
document.getElementById ('intro_formats_title').innerHTML = Loc ('Check an example file:');
55+
56+
let website = new Website ({
5157
headerDiv : document.getElementById ('header'),
5258
headerButtonsDiv : document.getElementById ('header_buttons'),
5359
toolbarDiv : document.getElementById ('toolbar'),

website/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,10 @@
6868
<div class="intro_content" id="intro_content">
6969
<div class="intro_logo">
7070
<svg class="intro_logo"><use href="assets/images/3dviewer_net_logo_text.svg#logo"></use></svg>
71-
<div class="intro_dragdrop_text">Drag and drop 3D models here.</div>
71+
<div class="intro_dragdrop_text" id="intro_dragdrop_text"></div>
7272
</div>
7373
<div class="intro_formats">
74-
<div class="intro_formats_title">Check an example file:</div>
74+
<div class="intro_formats_title" id="intro_formats_title"></div>
7575
<div class="intro_file_formats">
7676
<a href="#model=assets/models/RhinoLogo.3dm">3dm</a>
7777
<a href="#model=assets/models/cubes.3ds,assets/models/texture.png">3ds</a>

0 commit comments

Comments
 (0)