summaryrefslogtreecommitdiffstats
path: root/gfx/wr/debugger/src/components/ScreenshotPage.vue
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
commit2aa4a82499d4becd2284cdb482213d541b8804dd (patch)
treeb80bf8bf13c3766139fbacc530efd0dd9d54394c /gfx/wr/debugger/src/components/ScreenshotPage.vue
parentInitial commit. (diff)
downloadfirefox-2aa4a82499d4becd2284cdb482213d541b8804dd.tar.xz
firefox-2aa4a82499d4becd2284cdb482213d541b8804dd.zip
Adding upstream version 86.0.1.upstream/86.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'gfx/wr/debugger/src/components/ScreenshotPage.vue')
-rw-r--r--gfx/wr/debugger/src/components/ScreenshotPage.vue32
1 files changed, 32 insertions, 0 deletions
diff --git a/gfx/wr/debugger/src/components/ScreenshotPage.vue b/gfx/wr/debugger/src/components/ScreenshotPage.vue
new file mode 100644
index 0000000000..8d4017856e
--- /dev/null
+++ b/gfx/wr/debugger/src/components/ScreenshotPage.vue
@@ -0,0 +1,32 @@
+<template>
+ <div class="box">
+ <h1 class="title">Screenshot <a :disabled="disabled" v-on:click="fetch" class="button is-info">Refresh</a></h1>
+ <hr/>
+ <div>
+ <ul>
+ <img v-if="screenshot.length > 0" style="transform: scaleY(-1); width: 1024px; height:768px" :src="'data:image/png;base64,' + screenshot" />
+ </ul>
+ </div>
+ </div>
+</template>
+
+<script>
+export default {
+ computed: {
+ disabled() {
+ return !this.$store.state.connected
+ },
+ screenshot() {
+ return this.$store.state.screenshot
+ },
+ },
+ methods: {
+ fetch: function() {
+ this.$store.dispatch('sendMessage', "fetch_screenshot");
+ }
+ },
+}
+</script>
+
+<style>
+</style>