chromium

Chromium 基础库使用说明

夙愿已清 提交于 2019-12-27 21:37:40
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> Chromium 基础库使用说明 chromium base 作者: 易旭昕 ( @roger2yi ) Chromium 提供了一个类似 WTF 的基础库,甚至包含了更多的内容。这个基础库在 Blink 之外被广泛使用(Blink 里面仍然使用的是 WTF),了解它的使用对我们实际的代码编写是十分重要的。本文主要介绍 Chromium 基础库包括的主要内容,并详细说明一些重要类型的使用方式。如果需要了解某个特定目录或者文件的内容概要,学辉的 这篇文档 可以提供一个不错的全面索引,另外 Chromium 为所有的基础库类型都提供了完整的单元测试,通过阅读单元测试代码了解这些类型的使用也是很好的方式。 Chromium 基础库概览 Chromium 基础库包括的内容十分繁杂,我把其中的主要部分大致分为以下几类: 容器类型 Chromium 的代码主要使用 STL 容器类型,比如 std::vector,std::list,另外 GCC 和 MSVC 提供的 STL 扩展容器类型 hash_map 和 hash_set 也在 Chromium 中使用,不过统一放在 base 名字空间里面,通过 base::hash_map , base_hash_set 使用。 在 STL 外,Chromium

Chromium的智能指针/引用计数/Callback/Bind

风格不统一 提交于 2019-12-27 21:35:00
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> 这四个东西对使用者来说不难,看懂代码注释里的例子即可,预计1小时左右看懂全部。要去理解其设计思想的话最需要掌握的是模板类的使用,但一般使用者完全不用关心怎么设计的。 使用者的学习路径: 1.智能删除指针scoped_ptr 用作对普通指针的转储,防止忘记delete或不知道哪里delete。它跟引用计数没有关系。 头文件的注释就是使用示例 http://src.chromium.org/viewvc/chrome/trunk/src/base/memory/scoped_ptr.h template <class T, class D = base::DefaultDeleter<T> > class scoped_ptr 其中Deleter可以被替换,默认的Deleter区分是要delete普通指针还是指针数组,或者用free函数删除malloc的内存。 2. ScopedVector http://src.chromium.org/viewvc/chrome/trunk/src/base/memory/scoped_vector.h 在析构时会delete其元素的vector,知道它的行为即可。 3.带引用计数的类 http://src.chromium.org/viewvc/chrome/trunk

chromium 源码编译

人盡茶涼 提交于 2019-12-27 07:27:58
chromium发布已经有了很长一段时间,很早就下载编译了。由于太大。SVN下载总是断线。让我很苦恼。所以选着下载官方定期出的压缩包版本。 参考官方的编译说明文档 http://dev.chromium.org/developers/how-tos/build-instructions-windows 下面讲讲编译的几点细节问题。 (1) 工程文件修复 解压压缩包后,要对项目工程文件进行修复工作。不然VS2005无法正常的打开工程文件。 解决方法:下载depot_tools.zip工具,解压后,在下载python-2.4.msi 并安装,然后 设置系统的环境变量 PATH为 I:\home\chrome-svn\tarball\chromium\depot_tools;C:\Python24 在命令行敲入 C:\Program Files\Microsoft Visual Studio 8\VC>I: I:\>cd I:\home\chrome-svn\tarball\chromium\ I:\home\chrome-svn\tarball\chromium>src\tools\gyp\gyp.bat src\build\all.gyp 执行完,工程则修复完毕。 (2)SDK6.1 只要安装编译库和工具哪部分就可以了。 Start > All Programs >

编译chromium 总结

有些话、适合烂在心里 提交于 2019-12-27 07:23:07
http://www.chromium.org/developers/how-tos/build-instructions-windows 这是官网的详细地址,但我只用他的说明还不够 可以参考这篇文章 http://blog.sina.com.cn/s/blog_41608ead0101578b.html win7+vs2010+vs2010SP1+DIRECTX SDK (june版)+windows8 kit+ windows driver sdk 以上是需要配备的 windows 环境 (1)安装svn+python2.7.3(3.3不行), 将python,exe 的路径 加入 path环境变量里面 (2) 下载安装depot—tools ,将所在的路径加入到path环境变量 最后 (3) 然后修改chromium 代码里面的nativeclient 的一个py 文件 因为和这篇文章 http://blog.csdn.net/lhf_zj/article/details/7468282 出现相同的问题 就需要修改chromium\src\native_client\build\download_toolchains.py 这个文件 我修改之后的文件是 在 这里下载 ,然后放到相应目录 (4)windows 8 kit 要装到 program file(x86)这样的目录

How to build chromium for Android

纵饮孤独 提交于 2019-12-25 07:38:24
问题 I am trying to build Chromium for Android by following the instructions here: Android Build Instructions. When I finally run "~/chromium/src$ ninja -C out/Release chrome_public_apk", I get this error: "ninja: error: unknown target 'chrome_public_apk'" It seems that target is not built, in this link: Build Instructions (Android WebView), it says to run "build/gyp_chromium -DOS=android" before running the ninja command. However, I had followed the instructions for gn, what should I be calling

Building and debugging Chromium using visual studio giving error : error LNK1112: module machine type 'x64' conflicts with target machine type 'X86'

邮差的信 提交于 2019-12-25 06:55:08
问题 I want to debug the chromium code to check how it compiles the javascript code. I have downloaded the chromium code and trying to build cef solution file using visual studio but I am getting the following error: error LNK1112: module machine type 'x64' conflicts with target machine type 'X86' \third_party\libjpeg_turbo\jccolss2-64.obj cefclient error MSB3073: The command " call ninja.exe -C ..\out\Debug\ cefclient " exited with code 1. D:\Ishan\Chromium\Chromium\chromium\src\cef\cefclient

How do I install the Chromium package in Delphi?

允我心安 提交于 2019-12-25 05:32:53
问题 I downloaded the necessary from http://code.google.com/p/delphichromiumembedded/ with TortoiseSVN, but I do not know how to use it in Delphi XE2. How do I install the TChromium component? 回答1: To install the component, open the appropriate package - in your case, DCEF_XE2.dpk in packages directory and install the package. 来源: https://stackoverflow.com/questions/14124690/how-do-i-install-the-chromium-package-in-delphi

技术宅---我的网上抢火车票攻略

吃可爱长大的小学妹 提交于 2019-12-25 02:03:50
写在前面 写这篇文章的起因是今天在 12306 上买火车票时,被这牛逼的网站给震撼到了,靠,牛叉得让人无语的用户体验啊。就讲讲我是如何利用一个小工具做辅助,幸运地抢到了回家的卧铺票的。希望能给有需要的兄弟们做个参考。 回顾下我今天网上购票的全过程,总结起来有四个难关,第一是登陆,第二是预定,第三是提交订单,第四是支付。本文的目的主要是为了在第一和第二关提供一些帮助。 准备工作: 1 , firefox 浏览器 2 ,油猴脚本扩展 GreaseMonkey (有园友反映这里看不懂啥意思,好吧,特别补充一段。 GreaseMonkey 是一个 firefox 扩展,当然,别再问我啥是扩展了,请自行 google ,简单说,就是装了这个扩展,就可以再它基础上跑一些 js 脚本,对页面做一些修改什么的。。。,) 先去这个页面下载扩展, https://addons.mozilla.org/zh-cn/firefox/addon/greasemonkey/ , 下载到本地的是一个 xpi 文件,将其拖拽进 firefox 里面,就可以完成扩展的安装,重启 firefox 以后就生效,启用了 GreaseMonkey 3 ,去这个页面安装 12306 train ticket buyer 脚本, http://userscripts.org/scripts/show/122334

Chrome: message content-script on runtime.onInstalled

假如想象 提交于 2019-12-25 01:53:28
问题 I'm the maker of an addon called BeautifyTumblr which changes the apperance of Tumblr. I wish for my Chrome extension to automatically detect when it has been updated and display changelog to the user. I use an event page with the chrome.runtime.onInstalled.addListener hook to detect when an update has occured, retrieve the changelog from a text file in the extension.. this all works fine, then when I want to forward it to my content script via chrome.tabs.sendmessage it just wont work,

Node-Webkit: How to play AVI videos?

拟墨画扇 提交于 2019-12-25 01:49:31
问题 I am trying to make a simple node-webkit app that lets you play .avi videos (which should work both on windows and mac). Is there a way to do this with node-webkit? 回答1: It is unlikely you will be able to just do this with Node-Webkit. Especially since the official webkit does not support AVI. Your best bet is to use an external application like libav (avplay) or use node to serve a webpage that has a player capable of playing the content and just let the users browser do the work. (Flash is