summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
authorerikkay@chromium.org <erikkay@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-18 22:29:32 +0000
committererikkay@chromium.org <erikkay@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-18 22:29:32 +0000
commit07442307cd72bbe129cb87887438e82f146c0773 (patch)
tree4a526daa929741242fe2a29af1d106cc8e4cc1e3 /chrome/test
parent032b2c892ef67add767aa56dcf4f05b06f1f3d15 (diff)
downloadchromium_src-07442307cd72bbe129cb87887438e82f146c0773.zip
chromium_src-07442307cd72bbe129cb87887438e82f146c0773.tar.gz
chromium_src-07442307cd72bbe129cb87887438e82f146c0773.tar.bz2
Change the view mode when switching between moles and toolstrips, and
propogate this into the class of the document element so that it's possible to use CSS rules to control the display of your toolstrip/mole. BUG=21939,15494 TEST=run the Mappy extension and verify it can open and close Review URL: http://codereview.chromium.org/208020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26635 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test')
-rwxr-xr-xchrome/test/data/extensions/samples/mappy/mappy_toolstrip.html28
1 files changed, 16 insertions, 12 deletions
diff --git a/chrome/test/data/extensions/samples/mappy/mappy_toolstrip.html b/chrome/test/data/extensions/samples/mappy/mappy_toolstrip.html
index 9573344..88d1d52 100755
--- a/chrome/test/data/extensions/samples/mappy/mappy_toolstrip.html
+++ b/chrome/test/data/extensions/samples/mappy/mappy_toolstrip.html
@@ -1,6 +1,21 @@
<style>
-#map {
+.chrome-toolstrip #map {
display: none;
+}
+
+.chrome-toolstrip #button {
+ display: block;
+}
+
+.chrome-mole #map {
+ display: block;
+}
+
+.chrome-mole #button {
+ display: none;
+}
+
+#map {
width: 512px;
height: 512px;
}
@@ -10,20 +25,9 @@
<script>
var maps_key = "ABQIAAAATfHumDbW3OmRByfquHd3SRTRERdeAiwZ9EeJWta3L_JZVS0bOBRQeZgr4K0xyVKzUdnnuFl8X9PX0w";
-chrome.toolstrip.onCollapsed.addListener(function() {
- var map = document.getElementById("map");
- map.src = "";
- map.style.display = "none";
- var button = document.getElementById("button");
- button.style.display = "block";
-});
-
function expand(url) {
- var button = document.getElementById("button");
- button.style.display = "none";
var map = document.getElementById("map");
map.src = url;
- map.style.display = "block";
chrome.toolstrip.expand({height:512}, function() {});
}