View | Details | Raw Unified | Return to bug 41625
Collapse All | Expand All

(-)a/ucs-school-umc-computerroom/umc/js/computerroom/ScreenshotView.js (-5 / +10 lines)
 Lines 35-40   define([ Link Here 
35
	"dojo/aspect",
35
	"dojo/aspect",
36
	"dojo/dom",
36
	"dojo/dom",
37
	"dojo/dom-geometry",
37
	"dojo/dom-geometry",
38
	"dojox/html/entities",
38
	"dijit/layout/ContentPane",
39
	"dijit/layout/ContentPane",
39
	"dijit/_Contained",
40
	"dijit/_Contained",
40
	"dijit/Tooltip",
41
	"dijit/Tooltip",
 Lines 45-51   define([ Link Here 
45
	"umc/widgets/Page",
46
	"umc/widgets/Page",
46
	"umc/widgets/StandbyMixin",
47
	"umc/widgets/StandbyMixin",
47
	"umc/i18n!umc/modules/computerroom"
48
	"umc/i18n!umc/modules/computerroom"
48
], function(declare, lang, array, aspect, dom, geometry, ContentPane, _Contained, Tooltip,
49
], function(declare, lang, array, aspect, dom, geometry, entities, ContentPane, _Contained, Tooltip,
49
            /*TitlePane,*/ ComboBox, ContainerWidget, Button, Page, StandbyMixin, _) {
50
            /*TitlePane,*/ ComboBox, ContainerWidget, Button, Page, StandbyMixin, _) {
50
51
51
	// README: This is an alternative view
52
	// README: This is an alternative view
 Lines 190-198   define([ Link Here 
190
			this.inherited( arguments );
191
			this.inherited( arguments );
191
192
192
			lang.mixin( this, {
193
			lang.mixin( this, {
193
				content: lang.replace( '<em style="font-style: normal; font-size: 80%; padding: 4px; border: 1px solid #000; color: #000; background: #fff; display: block;position: absolute; top: 14px; left: 0px;" id="em-{computer}"></em><img style="width: 100%;" id="img-{computer}"></img>', {
194
				content: lang.replace( '<em style="font-style: normal; font-size: 80%; padding: 4px; border: 1px solid #000; color: #000; background: #fff; display: block;position: absolute; top: 14px; left: 0px;" id="em-{computer}"></em><img style="width: 100%;" id="img-{computer}" alt="{alternative}"></img>', {
194
					computer: this.computer,
195
					computer: entities.encode(this.computer),
195
					width: this.defaultSize
196
					width: this.defaultSize,
197
					alternative: entities.encode(_('Please be patient while the connection establishes.'))
196
				} )
198
				} )
197
			} );
199
			} );
198
			this.startup();
200
			this.startup();
 Lines 200-206   define([ Link Here 
200
			// use dijit.Tooltip here to not hide screenshot tooltips if set up in user preferences
202
			// use dijit.Tooltip here to not hide screenshot tooltips if set up in user preferences
201
			var tooltip = new Tooltip({
203
			var tooltip = new Tooltip({
202
				'class': 'umcTooltip',
204
				'class': 'umcTooltip',
203
				label: lang.replace( '<div style="display: table-cell; vertical-align: middle; width: 440px;height: 400px;"><img id="screenshotTooltip-{0}" src="" style="width: 430px; display: block; margin-left: auto; margin-right: auto;"/></div>', [ this.computer ] ),
205
				label: lang.replace( '<div style="display: table-cell; vertical-align: middle; width: 440px;height: 400px;"><img alt="{1}" id="screenshotTooltip-{0}" src="" style="width: 430px; display: block; margin-left: auto; margin-right: auto;"/></div>', [
206
					entities.encode(this.computer),
207
					entities.encode(_('connecting...'))
208
				]),
204
				connectId: [ this.domNode ],
209
				connectId: [ this.domNode ],
205
				onShow: lang.hitch( this, function() {
210
				onShow: lang.hitch( this, function() {
206
					var image = dom.byId( 'screenshotTooltip-' + this.computer );
211
					var image = dom.byId( 'screenshotTooltip-' + this.computer );

Return to bug 41625