chromium

Chrome extension - Message Passing

大憨熊 提交于 2019-12-18 13:34:49
问题 I'm trying to get the info that is set on the Options Page to alter the behavior of my extension. Basically, if a checkbox on OptionsPage is set to true, the extension runs, otherwise it doesn't. I'm returning true on the background.html for testing purposes, but still, it doesn't work. Would you guys help me out? Thanks! Code being injected to the page: if(chrome.extension.sendRequest() == 'true') alert("checkbox set to true"); else alert("it is disabled"); background.html <script> chrome

CEF小白人系列1-认识CEF

我的未来我决定 提交于 2019-12-18 12:56:03
前言: 手头上有个项目需要做浏览器的相关功能,评估了几个嵌入式方案最后选定CEF作为开发基础。 在入坑新技术的时候第一选择是去官网学习,这是一个非常好的习惯。 CEF官网(请科学上网): https://bitbucket.org/chromiumembedded/cef 在官网上有详细的介绍,英文苦的兄弟可以谷歌翻译大概意思是对的。必须仔细阅读。 CEF的维基百科 https://en.wikipedia.org/wiki/Chromium_Embedded_Framework#Applications_using_CEF 什么是CEF: Chromium嵌入式框架(CEF)是一个将基于Chromium的浏览器嵌入到其他应用程序的简单框架。支持Windows, Linux, Mac平台。除了提供C/C++接口外,也有其他语言的移植版。 其实可以理解CEF是个基于Google Chromium项目的开源Web browser控件 CEF的历史: CEF有两种版本的Chromium Embedded Framework:CEF 1和CEF 3 在Chromium Content API出现后,CEF 2的开发被放弃。 CEF 1是基于Chromium WebKit API的单进程实现。它不再积极发展或支持。 CEF 3是基于Chromium Content API的多进程实现

Chrome extension: how to use serial port (now that apps are sunsetting)?

房东的猫 提交于 2019-12-18 11:56:20
问题 Aim : I am attempting to write a little "thing" that can talk from my browser to the COM port of an Arduino. Issue : My first attempt is to write an extension. Therefore I am requesting permission for serial in my manifest file. When loading the unpackaged extension via developer mode I receive the following error: 'serial' is only allowed for packaged apps, but this is a extension. I see here that packaged app is an outdated term and I guess they just mean Chrome app . Now unfortunately it

Keyboard Shortcuts in Google Chrome / Chromium Extensions

旧城冷巷雨未停 提交于 2019-12-18 11:34:27
问题 I've created a basic extension for Google Chrome to change the behavior of which tab is selected when you close a tab so that the selected tab is the last one you had selected instead of just the one before the tab you closed. I want to add keyboard shortcuts, and I've found a way to do that using jquery and jquery hotkeys, but the problem I'm finding is that the keyboard shortcuts only work once a page is loaded. So for example, if you open a new tab without going anywhere, the shortcut keys

Chromium localStorage not showing in Developer Tools

怎甘沉沦 提交于 2019-12-18 10:39:42
问题 Trying to view my test localStorage , I see nothing in the Storage section under Applications in the Developer Tools. However, using the console, I can access it, meaning its clearly there. Am I missing something or does this seem to be a bug I couldn't find anything about? I am using Chromium Version 57.0.2978.0 (64-bit) 回答1: Its a known Bug (#701413) They fixed it in version 59.0.3069.0 (#718482) I can see the localStorage of different domains like FB, but not from the current domain. When

Synchronous XMLHttpRequest deprecated

故事扮演 提交于 2019-12-18 08:40:57
问题 Today, I had to restart my browser due to some issue with an extension. What I found when I restarted it, was that my browser (Chromium) automatically updated to a new version that doesn't allow synchronous AJAX-requests anymore. Quote: Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check http://xhr.spec.whatwg.org/. I need synchronous AJAX-requests for my node.js applications to work though, as they

PAC support disabled because there is no system implementation

让人想犯罪 __ 提交于 2019-12-18 05:28:07
问题 I've recently upgraded my Nexus 4 to Android 4.4. Whilst debugging my app, I discovered message W/chromium(14962): [WARNING:proxy_service.cc(888)] PAC support disabled because there is no system implementation What does it mean ? Logcat 12-12 17:38:56.726: V/WebViewChromium(14962): Binding Chromium to the main looper Looper{41f91588} 12-12 17:38:56.736: I/chromium(14962): [INFO:library_loader_hooks.cc(112)] Chromium logging enabled: level = 0, default verbosity = 0 12-12 17:38:56.736: I

How to connect to Chromium Headless using Selenium

醉酒当歌 提交于 2019-12-18 02:38:15
问题 I would like to use chromium headless for automated testing using selenium. (https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md) I do have the headless version already running on 9222. So if i open http://10.252.100.33:9222/json/I do get [ { "description": "", "devtoolsFrontendUrl": "/devtools/inspector.html?ws=127.0.0.1:9223/devtools/page/0261be06-1271-485b-bdff-48e443de7a91", "id": "0261be06-1271-485b-bdff-48e443de7a91", "title": "The Chromium Projects", "type": "page"

How to reset chrome inspector?

做~自己de王妃 提交于 2019-12-18 02:15:23
问题 Something is wrong with my Chrome inspector, I would like to reset the Chrome inspector to out of the box settings. How could I do ? (wihout removing my whole Chrome) 回答1: Find the following two files and delete them. These files contain the settings for the inspector. chrome-devtools_devtools_0.localstorage chrome-devtools_devtools_0.localstorage-journal Please make sure to restart the Chrome again. Hope this helps. 回答2: Open DevTools by pressing F12 or ctrl + shift + i press F1 or click on

Run google-chrome with flags on Android

微笑、不失礼 提交于 2019-12-18 01:16:14
问题 There are command line flags (or "switches") that Chromium (and Chrome) accept in order to enable particular features or modify otherwise default functionality. Chromium Command Line Switches Run Chromium with flags Tried Chrome 41.0.xx and Chromium 43.0.xxx shell with: # echo "chrome <flags>" > /data/local/tmp/android-webview-command-line # echo "chrome <flags>" > /data/local/tmp/content-shell-command-line Any idea how to run chrome with flags on Android or directly add these into default