mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
- Auto-generate all C/C++ translation code (issue #33).
- Change index parameter types from int to size_t to make 0-based range implicit. - Make CefPrintOptions and CefMenuInfo proper wrapper classes. - Normalize the naming of menu-related types. - Remove unused command_line variable from test_suite.cc. git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@408 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@@ -851,7 +851,7 @@ bool CefV8ValueImpl::HasValue(const CefString& key)
|
||||
return obj->Has(GetV8String(key));
|
||||
}
|
||||
|
||||
bool CefV8ValueImpl::HasValue(int index)
|
||||
bool CefV8ValueImpl::HasValue(size_t index)
|
||||
{
|
||||
CEF_REQUIRE_UI_THREAD(false);
|
||||
if(!GetHandle()->IsObject()) {
|
||||
@@ -859,11 +859,6 @@ bool CefV8ValueImpl::HasValue(int index)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (index < 0) {
|
||||
NOTREACHED() << "invalid input parameter";
|
||||
return false;
|
||||
}
|
||||
|
||||
v8::HandleScope handle_scope;
|
||||
v8::Local<v8::Object> obj = GetHandle()->ToObject();
|
||||
return obj->Has(index);
|
||||
@@ -887,7 +882,7 @@ bool CefV8ValueImpl::DeleteValue(const CefString& key)
|
||||
return obj->Delete(GetV8String(key));
|
||||
}
|
||||
|
||||
bool CefV8ValueImpl::DeleteValue(int index)
|
||||
bool CefV8ValueImpl::DeleteValue(size_t index)
|
||||
{
|
||||
CEF_REQUIRE_UI_THREAD(false);
|
||||
if(!GetHandle()->IsObject()) {
|
||||
@@ -895,11 +890,6 @@ bool CefV8ValueImpl::DeleteValue(int index)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (index < 0) {
|
||||
NOTREACHED() << "invalid input parameter";
|
||||
return false;
|
||||
}
|
||||
|
||||
v8::HandleScope handle_scope;
|
||||
v8::Local<v8::Object> obj = GetHandle()->ToObject();
|
||||
return obj->Delete(index);
|
||||
@@ -923,7 +913,7 @@ CefRefPtr<CefV8Value> CefV8ValueImpl::GetValue(const CefString& key)
|
||||
return new CefV8ValueImpl(obj->Get(GetV8String(key)));
|
||||
}
|
||||
|
||||
CefRefPtr<CefV8Value> CefV8ValueImpl::GetValue(int index)
|
||||
CefRefPtr<CefV8Value> CefV8ValueImpl::GetValue(size_t index)
|
||||
{
|
||||
CEF_REQUIRE_UI_THREAD(NULL);
|
||||
if(!GetHandle()->IsObject()) {
|
||||
@@ -931,11 +921,6 @@ CefRefPtr<CefV8Value> CefV8ValueImpl::GetValue(int index)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (index < 0) {
|
||||
NOTREACHED() << "invalid input parameter";
|
||||
return NULL;
|
||||
}
|
||||
|
||||
v8::HandleScope handle_scope;
|
||||
v8::Local<v8::Object> obj = GetHandle()->ToObject();
|
||||
return new CefV8ValueImpl(obj->Get(v8::Number::New(index)));
|
||||
@@ -963,7 +948,7 @@ bool CefV8ValueImpl::SetValue(const CefString& key,
|
||||
}
|
||||
}
|
||||
|
||||
bool CefV8ValueImpl::SetValue(int index, CefRefPtr<CefV8Value> value)
|
||||
bool CefV8ValueImpl::SetValue(size_t index, CefRefPtr<CefV8Value> value)
|
||||
{
|
||||
CEF_REQUIRE_UI_THREAD(false);
|
||||
|
||||
@@ -972,11 +957,6 @@ bool CefV8ValueImpl::SetValue(int index, CefRefPtr<CefV8Value> value)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (index < 0) {
|
||||
NOTREACHED() << "invalid input parameter";
|
||||
return false;
|
||||
}
|
||||
|
||||
CefV8ValueImpl *impl = static_cast<CefV8ValueImpl*>(value.get());
|
||||
if(impl) {
|
||||
v8::HandleScope handle_scope;
|
||||
|
Reference in New Issue
Block a user