webContents: api to add/remove path from devtools workspace

This commit is contained in:
Robo 2015-07-24 15:09:11 +05:30
parent 1bc49487ad
commit 66553eea1a
5 changed files with 59 additions and 18 deletions

View file

@ -37,8 +37,8 @@ class WebContents : public mate::TrackableObject<WebContents>,
public content::WebContentsObserver {
public:
// For node.js callback function type: function(error, buffer)
typedef base::Callback<void(v8::Local<v8::Value>, v8::Local<v8::Value>)>
PrintToPDFCallback;
using PrintToPDFCallback =
base::Callback<void(v8::Local<v8::Value>, v8::Local<v8::Value>)>;
// Create from an existing WebContents.
static mate::Handle<WebContents> CreateFrom(
@ -83,6 +83,10 @@ class WebContents : public mate::TrackableObject<WebContents>,
void PrintToPDF(const base::DictionaryValue& setting,
const PrintToPDFCallback& callback);
// DevTools workspace api.
void AddWorkSpace(const base::FilePath& path);
void RemoveWorkSpace(const base::FilePath& path);
// Editing commands.
void Undo();
void Redo();