Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(469)

Side by Side Diff: dart/site/try/src/ui.dart

Issue 269153003: Fix position of error messages. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Merged with r35883. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « dart/site/try/src/interaction_manager.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library trydart.ui; 5 library trydart.ui;
6 6
7 import 'dart:html'; 7 import 'dart:html';
8 8
9 import 'dart:async' show 9 import 'dart:async' show
10 Future, 10 Future,
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 buildUI() { 97 buildUI() {
98 interaction = new InteractionManager(); 98 interaction = new InteractionManager();
99 99
100 CompilationUnit.onChanged.listen(interaction.onCompilationUnitChanged); 100 CompilationUnit.onChanged.listen(interaction.onCompilationUnitChanged);
101 101
102 window.localStorage['currentSample'] = '$currentSample'; 102 window.localStorage['currentSample'] = '$currentSample';
103 103
104 buildCode(interaction); 104 buildCode(interaction);
105 105
106 (mainEditorPane = new DivElement()) 106 (mainEditorPane = new DivElement())
107 ..classes.addAll(['well', 'mainEditorPane']) 107 ..classes.addAll(['mainEditorPane'])
108 ..style.backgroundColor = currentTheme.background.color 108 ..style.backgroundColor = currentTheme.background.color
109 ..style.color = currentTheme.foreground.color 109 ..style.color = currentTheme.foreground.color
110 ..style.font = codeFont 110 ..style.font = codeFont
111 ..spellcheck = false; 111 ..spellcheck = false;
112 112
113 mainEditorPane 113 mainEditorPane
114 ..contentEditable = 'true' 114 ..contentEditable = 'true'
115 ..onKeyDown.listen(interaction.onKeyUp) 115 ..onKeyDown.listen(interaction.onKeyUp)
116 ..onInput.listen(interaction.onInput); 116 ..onInput.listen(interaction.onInput);
117 117
118 document.onSelectionChange.listen(interaction.onSelectionChange); 118 document.onSelectionChange.listen(interaction.onSelectionChange);
119 119
120 var inputWrapper = new DivElement() 120 var inputWrapper = new DivElement()
121 ..append(mainEditorPane) 121 ..append(mainEditorPane)
122 ..style.position = 'relative'; 122 ..classes.add('well')
123 ..style.padding = '0px'
124 ..style.overflowX = 'hidden'
125 ..style.overflowY = 'scroll'
126 ..style.position = 'relative'
127 ..style.maxHeight = '80vh';
123 128
124 var inputHeader = new DivElement()..appendText('Code'); 129 var inputHeader = new DivElement()..appendText('Code');
125 130
126 inputHeader.style 131 inputHeader.style
127 ..right = '3px' 132 ..right = '3px'
128 ..top = '0px' 133 ..top = '0px'
129 ..position = 'absolute'; 134 ..position = 'absolute';
130 inputWrapper.append(inputHeader); 135 inputWrapper.append(inputHeader);
131 136
132 statusDiv = new DivElement(); 137 statusDiv = new DivElement();
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
482 window.localStorage['compilationPaused'] = '$compilationPaused'; 487 window.localStorage['compilationPaused'] = '$compilationPaused';
483 window.localStorage['codeFont'] = '$codeFont'; 488 window.localStorage['codeFont'] = '$codeFont';
484 489
485 dialog.style.height = '0px'; 490 dialog.style.height = '0px';
486 } 491 }
487 form.onSubmit.listen(onSubmit); 492 form.onSubmit.listen(onSubmit);
488 493
489 var doneButton = document.getElementById('settings-done'); 494 var doneButton = document.getElementById('settings-done');
490 doneButton.onClick.listen(onSubmit); 495 doneButton.onClick.listen(onSubmit);
491 } 496 }
OLDNEW
« no previous file with comments | « dart/site/try/src/interaction_manager.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698