Commit cfafd1a6 authored by Zain Afzal's avatar Zain Afzal Committed by Commit Bot

Remove placeholder file navigation UI.

Previously we used a invisible overlay ontop of the guest iframe to hold
two green buttons for navigating forward and backwards in the current
directory. Since then we have moved the navigation ui down into the guest
frame (see cl/304099160) for better behavior, UX and a11y. This Cl
removes this invisible overlay and the two buttons as they are no longer
needed.


Bug: 996088
Change-Id: Ic9307d90f9fb3ecd1f5a5ef30d4e078810625833
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2131676Reviewed-by: default avatarTrent Apted <tapted@chromium.org>
Commit-Queue: Zain Afzal <zafzal@google.com>
Cr-Commit-Position: refs/heads/master@{#755281}
parent e9671e23
...@@ -21,44 +21,9 @@ ...@@ -21,44 +21,9 @@
height: 100%; height: 100%;
width: 100%; width: 100%;
} }
/*
* Container for the UI that overlays the sandboxed guest. Used for hosting UI
* components deemed to be privileged (e.g. to detect user gestures).
*/
div#overlay {
display: grid;
grid-template-rows: auto 40px auto;
grid-template-columns: 40px auto 40px;
height: 100%;
justify-items: stretch;
left: 0;
pointer-events: none;
position: absolute;
top: 0;
width: 100%;
}
div.navigation-button {
pointer-events: auto;
grid-row: 2;
background-color: green;
opacity: 0;
}
div.navigation-button:hover {
opacity: 0.5;
}
div#prev-container {
grid-column: 1;
}
div#next-container {
grid-column: 3;
}
</style> </style>
<script src="chrome://resources/mojo/mojo/public/js/mojo_bindings_lite.js"></script> <script src="chrome://resources/mojo/mojo/public/js/mojo_bindings_lite.js"></script>
<script src="/media_app.mojom-lite.js"></script> <script src="/media_app.mojom-lite.js"></script>
<script src="/mojo_api_bootstrap.js"></script> <script src="/mojo_api_bootstrap.js"></script>
<iframe src="chrome-untrusted://media-app/app.html" allow="fullscreen"></iframe> <iframe src="chrome-untrusted://media-app/app.html" allow="fullscreen"></iframe>
<div id="overlay">
<div id="prev-container" class="navigation-button"></div>
<div id="next-container" class="navigation-button"></div>
</div>
<script src="/media_app_index_scripts.js"></script> <script src="/media_app_index_scripts.js"></script>
...@@ -191,11 +191,6 @@ async function advance(direction) { ...@@ -191,11 +191,6 @@ async function advance(direction) {
await sendFilesToGuest(); await sendFilesToGuest();
} }
document.querySelector('#prev-container')
.addEventListener('click', () => advance(-1));
document.querySelector('#next-container')
.addEventListener('click', () => advance(1));
// Wait for 'load' (and not DOMContentLoaded) to ensure the subframe has been // Wait for 'load' (and not DOMContentLoaded) to ensure the subframe has been
// loaded and is ready to respond to postMessage. // loaded and is ready to respond to postMessage.
window.addEventListener('load', () => { window.addEventListener('load', () => {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment