How to use _screenshot method in ATX

Best Python code snippet using ATX

uber-controller.js

Source:uber-controller.js Github

copy

Full Screen

...32 delay: 1000,33 timeout: 2000034 }) => {35 console.log(`Waiting for selector (${desc}): ${selector}`);36 await _screenshot(page, `click_before_wait_${desc}_${Date.now()}`);37 await page.waitForSelector(selector, {timeout: timeout});38 await _screenshot(page, `click_after_wait_${desc}_${Date.now()}`);39 console.log(`Selector found in page`);40 await page.click(selector);41 await _screenshot(page, `click_after_click_${desc}_${Date.now()}`);42 console.log(`Clicked selector. Now waiting ${delay}ms`);43 await page.waitFor(delay);44 await _screenshot(page, `click_after_second_wait_${desc}_${Date.now()}`);45 console.log(`Done waiting.`);46}47const _wait_for_function_and_perform_func = async (page,48 wait_func,49 wait_func_params,50 exec_func = null,51 exec_func_params = null,52 {53 desc = "",54 delay = 1000,55 timeout = 2000056 } =57 {58 desc: "",59 delay: 1000,60 timeout: 2000061 }) => {62 console.log(`Waiting for function (${desc})`);63 await _screenshot(page, `before_wait_for_wait_func_${desc}_${Date.now()}`);64 await page.waitForFunction(wait_func, {timeout: timeout}, ...wait_func_params);65 await _screenshot(page, `after_wait_for_wait_func_${desc}_${Date.now()}`);66 if (!exec_func) {67 console.log("No exec function...returning.");68 return null;69 }70 const retVal = await page.evaluate(exec_func, ...exec_func_params);71 await _screenshot(page, `after_evaluate_exec_func_${desc}_${Date.now()}`);72 await page.waitFor(delay);73 await _screenshot(page, `after_wait_for_second_wait_for_wait_func_${desc}_${Date.now()}`);74 console.log(`Done waiting.`);75 return retVal;76}77const _wait_for_selector_and_select = async (page,78 selector,79 value,80 {81 desc = "",82 delay = 1000,83 timeout = 20000,84 hideValue = false,85 } =86 {87 desc: "",88 delay: 1000,89 timeout: 20000,90 hideValue: false,91 }) => {92 console.log(`Waiting for selector (${desc}): ${selector}`);93 await _screenshot(page, `select_before_wait_${desc}_${Date.now()}`);94 await page.waitForSelector(selector, {timeout: timeout});95 console.log(`Selector found in page`);96 await _screenshot(page, `select_after_wait_${desc}_${Date.now()}`);97 await page.select(selector, value);98 const redactedValue = hideValue ? "*******" : value;99 console.log(`Selected ${redactedValue} from dropdown. Now waiting ${delay}ms`);100 await _screenshot(page, `select_after_select_${desc}_${Date.now()}`);101 await page.waitFor(delay);102 await _screenshot(page, `select_after_second_wait_${desc}_${Date.now()}`);103 console.log(`Done waiting.`);104}105const _wait_for_selector_and_type = async (page,106 selector,107 value,108 {109 desc = "",110 delay = 1000,111 timeout = 10000,112 hideValue = false,113 } =114 {115 desc: "",116 delay: 1000,117 timeout: 10000,118 hideValue: false,119 }) => {120 console.log(`Waiting for selector (${desc}): ${selector}`);121 await _screenshot(page, `type_before_wait_${desc}_${Date.now()}`);122 await page.waitForSelector(selector, {timeout: timeout});123 console.log(`Selector found in page`);124 await _screenshot(page, `type_after_wait_${desc}_${Date.now()}`);125 await page.type(selector, value);126 const redactedValue = hideValue ? "*******" : value;127 await _screenshot(page, `type_after_type_${desc}_${Date.now()}`);128 console.log(`Typed ${redactedValue} into field. Now waiting ${delay}ms`);129 await page.waitFor(delay);130 await _screenshot(page, `type_after_second_wait_${desc}_${Date.now()}`);131 console.log(`Done waiting.`);132}133const _click_and_wait_ms = async (page, selector, ms) => {134 await page.click(selector);135 await page.waitFor(ms);136}137const _click_and_wait_ms_deprecated = (page, selector, ms) => Promise.all([138 page.evaluate((selector) => document.querySelector(selector).click(), selector),139 page.waitFor(ms),140]);141const _wait_for_selector = async (page, selector, delay, timeout) => {142 await page.waitForSelector(selector, {timeout: timeout});143 await page.waitFor(delay);144}...

Full Screen

Full Screen

indicator.js

Source:indicator.js Github

copy

Full Screen

1// vi: sts=2 sw=2 et2const Lang = imports.lang;3const Signals = imports.signals;4const St = imports.gi.St;5const Cogl = imports.gi.Cogl;6const Shell = imports.gi.Shell;7const Clutter = imports.gi.Clutter;8const PanelMenu = imports.ui.panelMenu;9const PopupMenu = imports.ui.popupMenu;10const Slider = imports.ui.slider;11const Gettext = imports.gettext.domain('gnome-shell-screenshot');12const _ = Gettext.gettext;13const ExtensionUtils = imports.misc.extensionUtils;14const Local = ExtensionUtils.getCurrentExtension();15const Config = Local.imports.config.exports;16const Convenience = Local.imports.convenience.exports;17const { dump } = Local.imports.dump.exports;18const DefaultIcon = 'camera-photo-symbolic';19const settings = Convenience.getSettings();20const CaptureDelayMenu = new Lang.Class({21 Name: 'CaptureDelayMenu',22 Extends: PopupMenu.PopupMenuSection,23 createScale: function () {24 let scale = [0];25 for (let p = 1; p < 4; p ++) {26 for (let x = 1; x <= 10; x += 1) {27 scale.push(x * Math.pow(10, p));28 }29 }30 return scale;31 },32 _init: function(control) {33 this.parent();34 this.scaleMS = this.createScale();35 this.delayValueMS = settings.get_int(Config.KeyCaptureDelay);36 this.slider = new Slider.Slider(this.scaleToSlider(this.delayValueMS));37 this.slider.connect('value-changed', this.onDragEnd.bind(this));38 this.sliderItem = new PopupMenu.PopupBaseMenuItem({ activate: false });39 this.sliderItem.actor.add(this.slider.actor, { expand: true });40 this.addMenuItem(this.sliderItem);41 this.delayInfoItem = new PopupMenu.PopupMenuItem(42 '', { activate: false, hover: false, can_focus: false }43 );44 this.addMenuItem(this.delayInfoItem)45 this.updateDelayInfo();46 },47 scaleToSlider: function (ms) {48 return this.scaleMS.findIndex((v) => v >= ms) / (this.scaleMS.length-1);49 },50 sliderToScale: function (value) {51 return this.scaleMS[(value * (this.scaleMS.length-1)) | 0];52 },53 onDragEnd: function(slider, value, property) {54 const newValue = this.sliderToScale(value);55 if (newValue !== this.delayValueMS) {56 this.delayValueMS = newValue;57 settings.set_int(Config.KeyCaptureDelay, newValue);58 this.updateDelayInfo();59 }60 },61 updateDelayInfo: function() {62 const v = this.delayValueMS;63 let text;64 if (v === 0) {65 text = _('No Capture Delay');66 } else if (v < 1000) {67 text = `${v}ms ` + _('Capture Delay');68 } else {69 text = `${v / 1000}s ` + _('Capture Delay');70 }71 this.delayInfoItem.label.text = text;72 }73});74const ScreenshotSection = new Lang.Class({75 Name: "ScreenshotTool.ScreenshotSection",76 _init: function (menu) {77 this._screenshot = null;78 this._image = new PopupMenu.PopupBaseMenuItem();79 this._image.actor.content_gravity =80 Clutter.ContentGravity.RESIZE_ASPECT;81 this._clear = new PopupMenu.PopupMenuItem(_('Clear'));82 this._copy = new PopupMenu.PopupMenuItem(_('Copy'));83 this._save = new PopupMenu.PopupMenuItem(_('Save As...'));84 this._image.connect('activate', this._onImage.bind(this));85 this._clear.connect('activate', this._onClear.bind(this));86 this._copy.connect('activate', this._onCopy.bind(this));87 this._save.connect('activate', this._onSave.bind(this));88 menu.addMenuItem(this._image);89 menu.addMenuItem(this._clear);90 menu.addMenuItem(this._copy);91 menu.addMenuItem(this._save);92 // IMGUR93 menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());94 this._imgurMenu = new PopupMenu.PopupSubMenuMenuItem(_('Imgur'), false);95 this._imgurUpload = new PopupMenu.PopupMenuItem(_('Upload'));96 this._imgurOpen = new PopupMenu.PopupMenuItem(_('Open Link'));97 this._imgurCopyLink = new PopupMenu.PopupMenuItem(_('Copy Link'));98 this._imgurDelete = new PopupMenu.PopupMenuItem(_('Delete'));99 this._imgurUpload.connect('activate', this._onImgurUpload.bind(this));100 this._imgurOpen.connect('activate', this._onImgurOpen.bind(this));101 this._imgurCopyLink.connect('activate', this._onImgurCopyLink.bind(this));102 this._imgurDelete.connect('activate', this._onImgurDelete.bind(this));103 this._imgurMenu.menu.addMenuItem(this._imgurUpload);104 this._imgurMenu.menu.addMenuItem(this._imgurOpen);105 this._imgurMenu.menu.addMenuItem(this._imgurCopyLink);106 this._imgurMenu.menu.addMenuItem(this._imgurDelete);107 menu.addMenuItem(this._imgurMenu);108 menu.connect("open-state-changed", () => {109 this._updateVisibility();110 });111 this._updateVisibility();112 },113 _updateVisibility: function () {114 let visible = !!this._screenshot;115 this._image.actor.visible = visible;116 this._clear.actor.visible = visible;117 this._copy.actor.visible = visible;118 this._save.actor.visible = visible;119 let imgurEnabled = settings.get_boolean(Config.KeyEnableUploadImgur);120 let imgurComplete =121 this._screenshot &&122 this._screenshot.imgurUpload &&123 this._screenshot.imgurUpload.responseData;124 this._imgurMenu.actor.visible =125 visible && imgurEnabled;126 this._imgurUpload.actor.visible =127 visible && imgurEnabled && !imgurComplete;128 this._imgurOpen.actor.visible =129 visible && imgurEnabled && imgurComplete;130 this._imgurCopyLink.actor.visible =131 visible && imgurEnabled && imgurComplete;132 this._imgurDelete.actor.visible =133 visible && imgurEnabled && imgurComplete;134 },135 _setImage: function (pixbuf) {136 let {width, height} = pixbuf;137 if (height == 0) {138 return;139 }140 let image = new Clutter.Image();141 let success = image.set_data(142 pixbuf.get_pixels(),143 pixbuf.get_has_alpha()144 ? Cogl.PixelFormat.RGBA_8888145 : Cogl.PixelFormat.RGB_888,146 width,147 height,148 pixbuf.get_rowstride()149 );150 if (!success) {151 throw Error("error creating Clutter.Image()");152 }153 this._image.actor.content = image;154 this._image.actor.height = 200;155 },156 setScreenshot: function (screenshot) {157 this._screenshot = screenshot;158 if (screenshot) {159 this._setImage(screenshot.gtkImage.get_pixbuf());160 this._screenshot.connect("imgur-upload", (obj, upload) => {161 upload.connect("done", (obj, data) => {162 this._updateVisibility();163 });164 });165 }166 this._updateVisibility();167 },168 _onImage: function () {169 this._screenshot.launchOpen();170 },171 _onClear: function () {172 this.setScreenshot(null);173 },174 _onCopy: function () {175 this._screenshot.copyClipboard();176 },177 _onSave: function () {178 this._screenshot.launchSave();179 },180 _onImgurUpload: function () {181 this._screenshot.imgurStartUpload();182 },183 _onImgurOpen: function () {184 this._screenshot.imgurOpenURL();185 },186 _onImgurCopyLink: function () {187 this._screenshot.imgurCopyURL();188 },189 _onImgurDelete: function () {190 this._screenshot.imgurDelete();191 }192})193const Indicator = new Lang.Class({194 Name: "ScreenshotTool.Indicator",195 Extends: PanelMenu.Button,196 _init: function (extension) {197 this.parent(null, Config.IndicatorName);198 this._extension = extension;199 this._signalSettings = [];200 this._icon = new St.Icon({201 icon_name: DefaultIcon,202 style_class: 'system-status-icon'203 });204 this.actor.add_actor(this._icon);205 this.actor.connect('button-press-event', this._onClick.bind(this));206 this._buildMenu();207 },208 _onClick: function (obj, evt) {209 // only override primary button behavior210 if (evt.get_button() !== Clutter.BUTTON_PRIMARY) {211 return;212 }213 let action = settings.get_string(Config.KeyClickAction);214 if (action === 'show-menu') {215 return;216 }217 this.menu.close();218 this._extension.onAction(action);219 },220 _buildMenu: function () {221 // These actions can be triggered via shortcut or popup menu222 const items = [223 ["select-area", _("Select Area")],224 ["select-window", _("Select Window")],225 ["select-desktop", _("Select Desktop")]226 ];227 items.forEach(([action, title]) => {228 let item = new PopupMenu.PopupMenuItem(title);229 item.connect(230 'activate', function (action) {231 this.menu.close();232 this._extension.onAction(action);233 }.bind(this, action)234 );235 this.menu.addMenuItem(item);236 })237 // Delay238 this.menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());239 this.menu.addMenuItem(new CaptureDelayMenu());240 this.menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());241 this._screenshotSection = new ScreenshotSection(this.menu);242 this.menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());243 // Settings can only be triggered via menu244 let settingsItem = new PopupMenu.PopupMenuItem(_('Settings'));245 settingsItem.connect('activate', () => {246 let appSys = Shell.AppSystem.get_default();247 let prefs = appSys.lookup_app('gnome-shell-extension-prefs.desktop');248 if (prefs.get_state() == prefs.SHELL_APP_STATE_RUNNING) {249 prefs.activate();250 } else {251 prefs.get_app_info().launch_uris(252 ['extension:///' + Local.metadata.uuid], null253 );254 }255 });256 this.menu.addMenuItem(settingsItem);257 },258 setScreenshot: function (screenshot) {259 this._screenshotSection.setScreenshot(screenshot);260 },261 destroy: function () {262 this.parent();263 this._signalSettings.forEach((signal) => {264 settings.disconnect(signal);265 });266 }267});268var exports = {269 Indicator...

Full Screen

Full Screen

controller.js

Source:controller.js Github

copy

Full Screen

1/*2 * This file is part of the ZombieBox package.3 *4 * Copyright © 2015-2020, Interfaced5 *6 * For the full copyright and license information, please view the LICENSE7 * file that was distributed with this source code.8 */9import app from 'generated/app';10import {div} from 'zb/html';11import AbstractApplication from 'zb/abstract-application';12import IKeyHandler from 'zb/interfaces/i-key-handler';13import Key from 'zb/device/input/key';14import EventPublisher from 'zb/events/event-publisher';15import Layer from 'zb/layers/layer';16import IMarkupProvider from './i-markup-provider';17import ScreenShot from './screenshot';18import UI, {PositionDiff} from './ui';19/**20 * @implements {IKeyHandler}21 */22export default class Controller {23 /**24 */25 constructor() {26 this._onChildLayerShown = this._onChildLayerShown.bind(this);27 this._onChildLayerHidden = this._onChildLayerHidden.bind(this);28 /**29 * @type {UI}30 * @protected31 */32 this._ui = null;33 /**34 * @type {number}35 * @protected36 */37 this._currentPosition = 0;38 /**39 * Default value is '77177'40 * @type {Array<Key>}41 * @protected42 */43 this._sequence = [44 Key.DIGIT_7,45 Key.DIGIT_7,46 Key.DIGIT_1,47 Key.DIGIT_7,48 Key.DIGIT_749 ];50 /**51 * @type {Array<string>}52 * @protected53 */54 this._screenshots = [];55 /**56 * @type {ScreenShot}57 * @protected58 */59 this._screenShot = null;60 /**61 * @type {Layer}62 * @protected63 */64 this._currentLayer = null;65 /**66 * @type {boolean}67 * @protected68 */69 this._isVisible = false;70 /**71 * @type {HTMLDivElement}72 * @protected73 */74 this._container = null;75 this._createUI();76 this._setViewState({77 x: 0,78 y: 0,79 opacity: 0.5,80 scale: false81 });82 }83 /**84 * @override85 */86 processKey(zbKey, event) {87 if (!this._isVisible) {88 const seq = this._sequence;89 this._currentPosition = this._currentPosition || 0;90 if (seq[this._currentPosition] !== zbKey) {91 this._currentPosition = 0;92 } else if (this._currentPosition === seq.length - 1) {93 this._currentPosition = 0;94 this.activate();95 return true;96 } else {97 this._currentPosition++;98 }99 } else {100 if (zbKey === Key.BACK) {101 this.deactivate();102 return true;103 }104 return this._ui.processKey(zbKey, event);105 }106 return false;107 }108 /**109 * Show PP UI and handle keys to perform manipulations with screenshot110 */111 activate() {112 this._isVisible = true;113 this._ui.show();114 this._screenShot.getContainer().style.display = 'block';115 // workaround for getting EVENT_AFTER_SHOW event on app start116 this._bindToLayer(app.getCurrentLayer());117 this._container.style.display = 'block';118 }119 /**120 * Hide PP UI121 */122 deactivate() {123 this._isVisible = false;124 this._ui.hide();125 this._screenShot.getContainer().style.display = 'none';126 this._container.style.display = 'none';127 }128 /**129 * @param {AbstractApplication} app130 */131 attachToApp(app) {132 this._getAppProperty(() => this._getAppBody(app), app, app.EVENT_DOM_READY)133 .then((appBody) => appBody.appendChild(this._container));134 this._getAppProperty(() => app.getLayerManager(), app, app.EVENT_DEVICE_READY)135 .then((lm) => {136 lm.on(lm.EVENT_AFTER_SHOW, (eventName, layer) =>137 this._bindToLayer(/** @type {Layer} */(layer)));138 this._bindToLayer(app.getCurrentLayer());139 });140 }141 /**142 * @param {string|Array<string>} url143 */144 setScreenShotUrl(url) {145 this._screenshots = url instanceof Array ? url : [url];146 this._renderScreenshot(this._screenshots[0]);147 }148 /**149 * @param {Array<Key>} seq150 */151 setKeySequence(seq) {152 this._sequence = seq;153 this._currentPosition = 0;154 }155 /**156 * @param {string} url157 * @protected158 */159 _renderScreenshot(url) {160 this._screenShot.setSource(url);161 this._ui.renderScreenshotValue(url);162 }163 /**164 * @protected165 */166 _createUI() {167 this._createContainer();168 this._screenShot = new ScreenShot();169 this._container.appendChild(this._screenShot.getContainer());170 this._screenShot.getContainer().style.display = 'none';171 this._ui = new UI(this._container);172 this._ui.on(this._ui.EVENT_CHANGE_OPACITY, (eventName, changeDiff) => this._setViewState({173 opacity: this._screenShot.getOpacity() + changeDiff * OPACITY_STEP174 }));175 this._ui.on(this._ui.EVENT_INVERT, () => this._setViewState({176 invert: this._screenShot.isInverted()177 }));178 this._ui.on(this._ui.EVENT_CHANGE_POSITION, (eventName, positionChangeDiff) => {179 positionChangeDiff = /** @type {PositionDiff} */ (positionChangeDiff);180 const position = this._screenShot.getPosition();181 const step = POSITION_STEP;182 if (positionChangeDiff.x) {183 position.x += step * positionChangeDiff.x;184 }185 if (positionChangeDiff.y) {186 position.y += step * positionChangeDiff.y;187 }188 this._setViewState({189 x: position.x,190 y: position.y191 });192 });193 this._ui.on(this._ui.EVENT_NEXT_SCREENSHOT, () => {194 if (this._screenshots.length > 1) {195 let nextIndex = this._screenshots.indexOf(this._screenShot.getSource()) + 1;196 if (nextIndex >= this._screenshots.length) {197 nextIndex = 0;198 }199 this._renderScreenshot(this._screenshots[nextIndex]);200 }201 });202 this._ui.on(this._ui.EVENT_TOGGLE, () => {203 const containerStyle = this._container.style;204 this._screenShot.getContainer().style.display = containerStyle.display === 'none' ? 'block' : 'none';205 });206 this._ui.on(this._ui.EVENT_TOGGLE_SCALE, () => this._setViewState({207 scale: this._screenShot.isScaled()208 }));209 }210 /**211 * @protected212 */213 _createContainer() {214 this._container = div();215 const containerStyle = this._container.style;216 containerStyle.position = 'absolute';217 containerStyle.top = '0';218 containerStyle.left = '0';219 containerStyle.width = '100%';220 containerStyle.height = '100%';221 containerStyle.zIndex = '1000';222 containerStyle.display = 'none';223 containerStyle.pointerEvents = 'none';224 }225 /**226 * @param {{227 * x: (number|undefined),228 * y: (number|undefined),229 * opacity: (number|undefined),230 * invert: (boolean|undefined),231 * scale: (boolean|undefined)232 * }} state233 * @protected234 */235 _setViewState(state) {236 if (state.x !== undefined || state.y !== undefined) {237 const position = {238 x: state.x !== undefined ? state.x : this._screenShot.getPosition().x,239 y: state.y !== undefined ? state.y : this._screenShot.getPosition().y240 };241 this._screenShot.setPosition(position.x, position.y);242 this._ui.renderPositionValue(position.x, position.y);243 }244 if (state.opacity !== undefined) {245 state.opacity = this._screenShot.setOpacity(state.opacity);246 this._ui.renderOpacityValue(state.opacity);247 }248 if (state.scale !== undefined) {249 this._screenShot.setScale(state.scale);250 this._ui.renderScaleValue(state.scale);251 }252 if (state.invert !== undefined) {253 this._screenShot.setInvert(state.invert);254 this._ui.renderInvertValue(state.invert);255 }256 }257 /**258 * @param {string} eventName259 * @param {Layer} layer260 * @protected261 */262 _onChildLayerShown(eventName, layer) {263 this._showScreenshotsFromLayer(layer);264 }265 /**266 * @protected267 */268 _onChildLayerHidden() {269 this._showScreenshotsFromLayer(this._currentLayer);270 }271 /**272 * @param {Layer} layer273 * @protected274 */275 _bindToLayer(layer) {276 if (this._currentLayer) {277 this._currentLayer.off(this._currentLayer.EVENT_CHILD_LAYER_SHOWN, this._onChildLayerShown);278 this._currentLayer.off(this._currentLayer.EVENT_CHILD_LAYER_HIDDEN, this._onChildLayerHidden);279 }280 this._currentLayer = layer;281 if (layer) {282 layer.on(layer.EVENT_CHILD_LAYER_SHOWN, this._onChildLayerShown);283 layer.on(layer.EVENT_CHILD_LAYER_HIDDEN, this._onChildLayerHidden);284 }285 this._showScreenshotsFromLayer(layer);286 }287 /**288 * @param {Layer} layer289 * @protected290 */291 _showScreenshotsFromLayer(layer) {292 const topLayer = layer ? layer.getTopChildLayer() || layer : null;293 const screenshots = this._getScreenShotsFromLayer(topLayer);294 if (screenshots && screenshots.length) {295 this.setScreenShotUrl(screenshots);296 } else {297 this.setScreenShotUrl('');298 }299 }300 /**301 * @param {Layer|IMarkupProvider} layer302 * @return {?Array<string>}303 * @protected304 */305 _getScreenShotsFromLayer(layer) {306 if (layer && typeof layer.getMarkupImage === 'function') {307 const mp = /** @type {IMarkupProvider} */ (layer);308 const screenshots = mp.getMarkupImage();309 return screenshots instanceof Array ? screenshots : [screenshots];310 }311 return null;312 }313 /**314 * @suppress {accessControls}315 * @param {AbstractApplication} app316 * @return {HTMLElement}317 * @protected318 */319 _getAppBody(app) {320 return app._body;321 }322 /**323 * @param {function(): *} getter324 * @param {EventPublisher} obj325 * @param {string} event326 * @return {Promise}327 * @protected328 */329 _getAppProperty(getter, obj, event) {330 return new Promise((resolve) => {331 const result = getter();332 if (result) {333 resolve(result);334 } else {335 obj.on(event, () => resolve(getter()));336 }337 });338 }339}340/**341 * @const {number}342 */343export const OPACITY_STEP = 0.05;344/**345 * @const {number}346 */...

Full Screen

Full Screen

screenshotcontrols.js

Source:screenshotcontrols.js Github

copy

Full Screen

...123 {124 this._screenshot = window.views.screenshot;125 }126 this._screenshot._take_screenshot = true;127 this._screenshot.update_screenshot(event.shiftKey);128 }.bind(this);129 this._handlers['screenshot-zoom'] = function(event, target)130 {131 if (!this._screenshot)132 {133 this._screenshot = window.views.screenshot;134 }135 this._scale = parseInt(event.target.value);136 this._screenshot.zoom_center(this._scale);137 this._ruler.scale = this._scale;138 }.bind(this);139 this._handlers['screenshot-sample-size'] = function(event, target)140 {141 if (!this._screenshot)...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run ATX automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful