Google chrome lock in fullscreen - google-chrome

I have a web application (directory slides) program which is preferable to run in fullscreen on google chrome. Now the problem is i would like to limit the user access to the browsers functionality so when the browser is in fullscreen i would like to lock it.
Is there any way to do these?

This is generally referred to as "Kiosk mode," and Chrome does appear to support it. From https://lifehacker.com/use-chromes-kiosk-mode-to-limit-someones-access-to-yo-1243433249:
Open up Chrome's settings.
Under "Users" click "Add new user."
Give the new profile a name and picture. Make sure "Create a desktop shortcut for this user" is checked. Click "Create."
Right-click the newly-created shortcut and select "Properties."
In the "Target" field, add "--kiosk" (no quotes) to the end.
Click "Apply."

Related

reset chrome media engagement score

I know that Chrome 66 introduced some restrictions when autoplaying a video (in HTML5).
In some cases the autoplay is supported. One of the conditions to support autoplay is when the user has watched a video in the domain before or something similar. So Chrome is keeping an internal score for each site. This score can be checked in chrome://media-engagement.
But now my problem is that for testing I have not figured it out a simple way to reset this score. So I can not properly test it for the new users.
Any idea?
A quick throwaway solution to have a new window with empty MEI data is to open a "Guest window" by clicking the user avatar and choosing "Open Guest window" button.
The easiest way I found to test using a clean score is to create a new profile in Chrome:
1- At the top right of Chrome, click the button with your name or People People.
2- Click Manage people.
3- Click Add person.
4- Click Save. A new window will open and ask you to sign in.
It is not recommended to manually make changes to your profile folder, but this worked for me.
Go to chrome://version/ and note the Profile Path
Close Chrome
Open the Preferences file in your profile folder with a text editor.
Delete the media_engagement entry.
Go to chrome://media-engagement to verify that everything has been cleared.
Alternatively you can just remove the Preferences file altogether but this removes a bunch of other things as well.
You can also clean MEI by clearing browsing history:
Click Ctrl+Shift+Del or navigate to chrome://settings/clearBrowserData
Go to Advanced > All time
tick Browsing history
Click Clear data
Navigate to chrome://media-engagement to verify
BTW. Note that notably going into incognito mode doesn't reset MEI; the MEI data are copied from regular session when opening first incognito tab (and then lives on its own until incognito session is closed).

Is there a way to add a chrome app shortcut to my bookmarks bar in Google Chrome?

Some Chrome extensions have bookmark icons that are automatically added to the bookmarks bar, but, so far as I can tell apps such as Postman can't be added directly to the shortcut bar.
If I want to launch an "app" (i.e. not one of the extensions which already show up in the toolbar) such as this, I have to open the "Apps" shortcut window, and then find the app (or launch it separately from the app launcher).
I would very much like to have a bookmark to a specific App in the bookmark bar. Is this possible?
It's not possible.
The closest implementable thing is an extension with a toolbar icon that launches specifically the app.
Or toolbar popup launchers like Apps Launcher or AppJump App Launcher and Organizer.
Not the direct answer to the question, but this question is about quickly launching signal.
Two other solutions include:
https://github.com/WhisperSystems/Signal-Desktop/pull/1262
Add a shortcut to your Launcher or Desktop
Have Signal Desktop already open
Right our Double click on your app icon
On Mac: Choose Options > Choose Keep in Dock
On Windows: Select More > Pin to taskbar
The shortcut Alt + S, however this is being Depreciated:

How to add an Google Chrome application to the taskbar?

I want to add to my application the ability to add it to the taskbar. Is there a API such an opportunity? Sorry for my english.
To my knowledge there is no API for this. When it's launched, it will appear on the taskbar, and then the user can right-click on the icon and pin it.
(I assume by "taskbar" you mean shortcuts/favorites icons on the taskbar)
Different OS's have different ways to do this.
On Linux, chrome apps are put in the start menu under a "Chrome Apps" group. From there, right-click to create shortcuts, add to panel, or favorites.
There doesn't appear to be an api to do this automatically: https://developer.chrome.com/apps/api_index
You're best bet may be to show the user how to access the app:
"Apps" on bookmark bar in Chrome
"Chrome Apps" in start menu

How to get warning massage when clicking close(X) button of browser with tabs in Google Chrome

How to get a warning massage if i accidently click the close button of the chrome browser which have multiple tabs opened at that time?
I am a regular user of Crome and having this problem while using it. I normally open multiple tabs inside a single browser but sometimes i accidently click the close button of browser and as soon as the button is clicked crome does't give any warning issue about multiple active tabs and close the entire window.
Is the end user like me is browsing on normal crome window then he can open the websites again by checking the web history but if he is browsing inside private browser then he can't do anything(this happens with me very regularly because i normally browse in private browser). On the other hand if you accidently click the close button in mozilla which have multiple tabs open it throws a warning massage to the user and asks for his wish.
Go find an extension called "Keep One Pinned Tab". It may not be exactly the function you need, but if you search for other extensions, I am sure there is such an extension that does just that. If you can't find one, I suggest to learn how to develop extensions and make one yourself, you can share it with others when it's done.

How to disable chrome extensions JS when debugging in devtools?

When I add mouse event breakpoint, devtools always jump into extension's JS.
Is there any way to point to my mouse event code directly?
The only way to disable the script (e.g. to avoid side-effects) is by disabling the extension (for instance, by using incognito mode if the extension is not enabled in incognito mode).
If you don't mind the scripts to run, but want to ignore extension code, then you can use the script blackboxing feature of Chrome's devtools.
If you never develop extensions and aren't interested in stepping through it, then open the settings menu of the devtools, click on Blackboxing and then the "Blackbox content scripts" checkbox:
If you only want to selectively ignore files, then you can also right-click on the source of the file that you want to ignore, and click on the "Blackbox Script" contextmenu option. To remove the pattern, go to the "Blackboxing" settings panel as shown before.
I think the simplest way is to open an incognito window (Ctrl-Shift-N) (or Cmd-Shift-N for mac) and debug in there, because then there will be no extensions loaded (by default).
I know what you mean by this question: when debugging, and doing something simple like pausing execution, you always find it breaks into one of the extension's codes instead of the current webpage's code.
open developer tools, then go to settings and then click on ignore list, and check the checkbox for add content script to ignore list, then add this to the ignore list: ^chrome-extension://
If you're using Google Chrome (or any Chromium-based browsers), simply run a new browser instance with a fresh user's data directory.
On Linux:
google-chrome --user-data-dir=$(mktemp -d)
This way, all extensions will be disabled without having to manually switch off/on them.
I like to use Profiles for that.
While changing into incognito mode might help you to disable most of the extensions, some of them might be allowed and still run. For example I have DarkReader and Ublock enabled in incognito mode.
My favorite workaround is to use a "Guest" profile or to create a profile that you can use for debugging. I think it is easier than creating a Framework Ignore List inside of devtools.
How to create a profile: https://support.google.com/chrome/answer/2364824
Example: My debugging profile
First off you should probably review the tutorial on how to debug chrome extensions here:
http://code.google.com/chrome/extensions/tut_debugging.html
When in doubt, you can always use the debugger keyword directly in the JavaScript code where you want to launch the debugger from, like so:
element.addEventListener("mouseover", function() {
debugger;
// some JS handler code...
});
Depending on if your JS is in a popup, background page, or in a content script, you will need make sure you launch the dev tools from the right place.
For a popup, you need to right click on the extension icon and "Inspect Popup" and then from the JavaScript console you would need to run location.reload(true)
For a background page, you need to go to the extensions settings page, chrome://settings/extensions, turn on developer mode, expand the extension in question and click the background page link.
The content script should be visible directly from the page it is loaded onto.