diff options
author | scherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-30 01:10:22 +0000 |
---|---|---|
committer | scherkus@chromium.org <scherkus@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-30 01:10:22 +0000 |
commit | 69e797f6f8534d551b5e9bcb3c559fa173c23e67 (patch) | |
tree | 213e4d17f64a9d8ab6cbad99f284c07092b3fe4d /content/browser | |
parent | a2f53dccfdc5d8ca95727030e648b6bafab6a0c9 (diff) | |
download | chromium_src-69e797f6f8534d551b5e9bcb3c559fa173c23e67.zip chromium_src-69e797f6f8534d551b5e9bcb3c559fa173c23e67.tar.gz chromium_src-69e797f6f8534d551b5e9bcb3c559fa173c23e67.tar.bz2 |
content: Remove use of ALLOW_THIS_IN_INITIALIZER_LIST.
It's no longer providing value as the MSVC warning is disabled during compilation. Refer to bug for details.
BUG=234765
R=jam@chromium.org
Review URL: https://codereview.chromium.org/14386012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@197206 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser')
45 files changed, 63 insertions, 72 deletions
diff --git a/content/browser/android/content_view_render_view.cc b/content/browser/android/content_view_render_view.cc index a9a3c32..f427bc3 100644 --- a/content/browser/android/content_view_render_view.cc +++ b/content/browser/android/content_view_render_view.cc @@ -31,7 +31,7 @@ bool ContentViewRenderView::RegisterContentViewRenderView(JNIEnv* env) { ContentViewRenderView::ContentViewRenderView() : scheduled_composite_(false), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { } ContentViewRenderView::~ContentViewRenderView() { diff --git a/content/browser/android/media_player_manager_android.cc b/content/browser/android/media_player_manager_android.cc index c046e59..4a093c7 100644 --- a/content/browser/android/media_player_manager_android.cc +++ b/content/browser/android/media_player_manager_android.cc @@ -24,7 +24,7 @@ namespace content { MediaPlayerManagerAndroid::MediaPlayerManagerAndroid( RenderViewHost* render_view_host) : RenderViewHostObserver(render_view_host), - ALLOW_THIS_IN_INITIALIZER_LIST(video_view_(this)), + video_view_(this), fullscreen_player_id_(-1), web_contents_(WebContents::FromRenderViewHost(render_view_host)) { } diff --git a/content/browser/android/media_resource_getter_impl.cc b/content/browser/android/media_resource_getter_impl.cc index 8c1177a..00f92d6 100644 --- a/content/browser/android/media_resource_getter_impl.cc +++ b/content/browser/android/media_resource_getter_impl.cc @@ -206,7 +206,7 @@ MediaResourceGetterImpl::MediaResourceGetterImpl( int renderer_id, int routing_id) : browser_context_(browser_context), file_system_context_(file_system_context), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_this_(this)), + weak_this_(this), renderer_id_(renderer_id), routing_id_(routing_id) { } diff --git a/content/browser/appcache/appcache_dispatcher_host.cc b/content/browser/appcache/appcache_dispatcher_host.cc index a01c9d7..90a5dc7 100644 --- a/content/browser/appcache/appcache_dispatcher_host.cc +++ b/content/browser/appcache/appcache_dispatcher_host.cc @@ -16,7 +16,7 @@ AppCacheDispatcherHost::AppCacheDispatcherHost( ChromeAppCacheService* appcache_service, int process_id) : appcache_service_(appcache_service), - ALLOW_THIS_IN_INITIALIZER_LIST(frontend_proxy_(this)), + frontend_proxy_(this), process_id_(process_id) { } diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc index 475a87f..fc04b7d 100644 --- a/content/browser/browser_plugin/browser_plugin_guest.cc +++ b/content/browser/browser_plugin/browser_plugin_guest.cc @@ -128,7 +128,7 @@ BrowserPluginGuest::BrowserPluginGuest( BrowserPluginGuest* opener, bool has_render_view) : WebContentsObserver(web_contents), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)), + weak_ptr_factory_(this), embedder_web_contents_(NULL), instance_id_(instance_id), damage_buffer_sequence_id_(0), diff --git a/content/browser/device_orientation/provider_impl.cc b/content/browser/device_orientation/provider_impl.cc index 78ae52d..4b88764 100644 --- a/content/browser/device_orientation/provider_impl.cc +++ b/content/browser/device_orientation/provider_impl.cc @@ -173,7 +173,7 @@ base::TimeDelta ProviderImpl::PollingThread::SamplingInterval() const { ProviderImpl::ProviderImpl(DataFetcherFactory factory) : creator_loop_(MessageLoop::current()), factory_(factory), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), + weak_factory_(this), polling_thread_(NULL) { } diff --git a/content/browser/devtools/devtools_browser_target.cc b/content/browser/devtools/devtools_browser_target.cc index aa5e1ac..fc563fb 100644 --- a/content/browser/devtools/devtools_browser_target.cc +++ b/content/browser/devtools/devtools_browser_target.cc @@ -22,7 +22,7 @@ DevToolsBrowserTarget::DevToolsBrowserTarget( http_server_(http_server), connection_id_(connection_id), handlers_deleter_(&handlers_), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { } DevToolsBrowserTarget::~DevToolsBrowserTarget() { diff --git a/content/browser/devtools/devtools_http_handler_unittest.cc b/content/browser/devtools/devtools_http_handler_unittest.cc index 3dd4789..5935a5e 100644 --- a/content/browser/devtools/devtools_http_handler_unittest.cc +++ b/content/browser/devtools/devtools_http_handler_unittest.cc @@ -19,7 +19,7 @@ class DummyListenSocket : public StreamListenSocket, public StreamListenSocket::Delegate { public: DummyListenSocket() - : ALLOW_THIS_IN_INITIALIZER_LIST(StreamListenSocket(0, this)) {} + : StreamListenSocket(0, this) {} // StreamListenSocket::Delegate "implementation" virtual void DidAccept(StreamListenSocket* server, diff --git a/content/browser/download/download_browsertest.cc b/content/browser/download/download_browsertest.cc index 1a2773c..2645479 100644 --- a/content/browser/download/download_browsertest.cc +++ b/content/browser/download/download_browsertest.cc @@ -213,7 +213,7 @@ void DownloadFileWithDelay::RenameCallbackWrapper( } DownloadFileWithDelayFactory::DownloadFileWithDelayFactory() - : weak_ptr_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), + : weak_ptr_factory_(this), waiting_(false) {} DownloadFileWithDelayFactory::~DownloadFileWithDelayFactory() {} diff --git a/content/browser/download/download_file_impl.cc b/content/browser/download/download_file_impl.cc index 5286e0c..9c064d2 100644 --- a/content/browser/download/download_file_impl.cc +++ b/content/browser/download/download_file_impl.cc @@ -50,7 +50,7 @@ DownloadFileImpl::DownloadFileImpl( bytes_seen_(0), bound_net_log_(bound_net_log), observer_(observer), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), + weak_factory_(this), power_save_blocker_(power_save_blocker.Pass()) { } diff --git a/content/browser/download/download_file_unittest.cc b/content/browser/download/download_file_unittest.cc index 95e3a9c..d26cbce 100644 --- a/content/browser/download/download_file_unittest.cc +++ b/content/browser/download/download_file_unittest.cc @@ -77,7 +77,7 @@ class DownloadFileTest : public testing::Test { DownloadFileTest() : observer_(new StrictMock<MockDownloadDestinationObserver>), - observer_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(observer_.get())), + observer_factory_(observer_.get()), bytes_(-1), bytes_per_sec_(-1), hash_state_("xyzzy"), diff --git a/content/browser/download/download_item_impl.cc b/content/browser/download/download_item_impl.cc index 7d5dd10..dfb915e 100644 --- a/content/browser/download/download_item_impl.cc +++ b/content/browser/download/download_item_impl.cc @@ -131,7 +131,7 @@ DownloadItemImpl::DownloadItemImpl(DownloadItemImplDelegate* delegate, opened_(opened), delegate_delayed_complete_(false), bound_net_log_(bound_net_log), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { delegate_->Attach(); DCHECK_NE(IN_PROGRESS_INTERNAL, state_); Init(false /* not actively downloading */, SRC_HISTORY_IMPORT); @@ -180,7 +180,7 @@ DownloadItemImpl::DownloadItemImpl( opened_(false), delegate_delayed_complete_(false), bound_net_log_(bound_net_log), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { delegate_->Attach(); Init(true /* actively downloading */, SRC_ACTIVE_DOWNLOAD); @@ -235,7 +235,7 @@ DownloadItemImpl::DownloadItemImpl( opened_(false), delegate_delayed_complete_(false), bound_net_log_(bound_net_log), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { delegate_->Attach(); Init(true /* actively downloading */, SRC_SAVE_PAGE_AS); } diff --git a/content/browser/download/drag_download_file.cc b/content/browser/download/drag_download_file.cc index d87a7e0..03dad10 100644 --- a/content/browser/download/drag_download_file.cc +++ b/content/browser/download/drag_download_file.cc @@ -46,7 +46,7 @@ class DragDownloadFile::DragDownloadFileUI : public DownloadItem::Observer { referrer_encoding_(referrer_encoding), web_contents_(web_contents), download_item_(NULL), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { DCHECK(on_completed_loop_); DCHECK(!on_completed_.is_null()); DCHECK(web_contents_); @@ -157,7 +157,7 @@ DragDownloadFile::DragDownloadFile(const base::FilePath& file_path, drag_message_loop_(MessageLoop::current()), state_(INITIALIZED), drag_ui_(NULL), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { drag_ui_ = new DragDownloadFileUI( url, referrer, diff --git a/content/browser/gamepad/gamepad_provider_unittest.cc b/content/browser/gamepad/gamepad_provider_unittest.cc index 18bafc3..12d8845 100644 --- a/content/browser/gamepad/gamepad_provider_unittest.cc +++ b/content/browser/gamepad/gamepad_provider_unittest.cc @@ -22,7 +22,7 @@ using WebKit::WebGamepads; class UserGestureListener { public: UserGestureListener() - : weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), + : weak_factory_(this), has_user_gesture_(false) { } diff --git a/content/browser/geolocation/gps_location_provider_linux.cc b/content/browser/geolocation/gps_location_provider_linux.cc index 74a9537..0481c62 100644 --- a/content/browser/geolocation/gps_location_provider_linux.cc +++ b/content/browser/geolocation/gps_location_provider_linux.cc @@ -216,7 +216,7 @@ GpsLocationProviderLinux::GpsLocationProviderLinux(LibGpsFactory libgps_factory) poll_period_moving_millis_(kPollPeriodMovingMillis), poll_period_stationary_millis_(kPollPeriodStationaryMillis), libgps_factory_(libgps_factory), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { DCHECK(libgps_factory_); } diff --git a/content/browser/geolocation/mock_location_provider.cc b/content/browser/geolocation/mock_location_provider.cc index e146f38..76471af 100644 --- a/content/browser/geolocation/mock_location_provider.cc +++ b/content/browser/geolocation/mock_location_provider.cc @@ -72,7 +72,7 @@ class AutoMockLocationProvider : public MockLocationProvider { AutoMockLocationProvider(bool has_valid_location, bool requires_permission_to_start) : MockLocationProvider(&instance_), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), + weak_factory_(this), requires_permission_to_start_(requires_permission_to_start), listeners_updated_(false) { if (has_valid_location) { diff --git a/content/browser/geolocation/network_location_provider.cc b/content/browser/geolocation/network_location_provider.cc index 0167fd9..e4aac74 100644 --- a/content/browser/geolocation/network_location_provider.cc +++ b/content/browser/geolocation/network_location_provider.cc @@ -114,7 +114,7 @@ NetworkLocationProvider::NetworkLocationProvider( access_token_(access_token), is_permission_granted_(false), is_new_data_available_(false), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { // Create the position cache. position_cache_.reset(new PositionCache()); diff --git a/content/browser/geolocation/wifi_data_provider_common.cc b/content/browser/geolocation/wifi_data_provider_common.cc index fd5667a..b00b0a2 100644 --- a/content/browser/geolocation/wifi_data_provider_common.cc +++ b/content/browser/geolocation/wifi_data_provider_common.cc @@ -27,7 +27,7 @@ string16 MacAddressAsString16(const uint8 mac_as_int[6]) { WifiDataProviderCommon::WifiDataProviderCommon() : Thread("Geolocation_wifi_provider"), is_first_scan_complete_(false), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { } WifiDataProviderCommon::~WifiDataProviderCommon() { diff --git a/content/browser/geolocation/win7_location_provider_win.cc b/content/browser/geolocation/win7_location_provider_win.cc index fa7122d..66f88a0 100644 --- a/content/browser/geolocation/win7_location_provider_win.cc +++ b/content/browser/geolocation/win7_location_provider_win.cc @@ -46,7 +46,7 @@ bool PositionsDifferSiginificantly(const Geoposition& position_1, } Win7LocationProvider::Win7LocationProvider(Win7LocationApi* api) - : ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + : weak_factory_(this) { DCHECK(api != NULL); api_.reset(api); } diff --git a/content/browser/hyphenator/hyphenator_message_filter.cc b/content/browser/hyphenator/hyphenator_message_filter.cc index 1653ea3..e14233a 100644 --- a/content/browser/hyphenator/hyphenator_message_filter.cc +++ b/content/browser/hyphenator/hyphenator_message_filter.cc @@ -31,7 +31,7 @@ HyphenatorMessageFilter::HyphenatorMessageFilter( RenderProcessHost* render_process_host) : render_process_host_(render_process_host), dictionary_file_(base::kInvalidPlatformFileValue), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { } HyphenatorMessageFilter::~HyphenatorMessageFilter() { diff --git a/content/browser/in_process_webkit/indexed_db_dispatcher_host.cc b/content/browser/in_process_webkit/indexed_db_dispatcher_host.cc index d498421..35ba143 100644 --- a/content/browser/in_process_webkit/indexed_db_dispatcher_host.cc +++ b/content/browser/in_process_webkit/indexed_db_dispatcher_host.cc @@ -63,10 +63,8 @@ void DeleteOnWebKitThread(T* obj) { IndexedDBDispatcherHost::IndexedDBDispatcherHost( int ipc_process_id, IndexedDBContextImpl* indexed_db_context) : indexed_db_context_(indexed_db_context), - ALLOW_THIS_IN_INITIALIZER_LIST(database_dispatcher_host_( - new DatabaseDispatcherHost(this))), - ALLOW_THIS_IN_INITIALIZER_LIST(cursor_dispatcher_host_( - new CursorDispatcherHost(this))), + database_dispatcher_host_(new DatabaseDispatcherHost(this)), + cursor_dispatcher_host_(new CursorDispatcherHost(this)), ipc_process_id_(ipc_process_id) { DCHECK(indexed_db_context_.get()); } diff --git a/content/browser/indexed_db/indexed_db_quota_client_unittest.cc b/content/browser/indexed_db/indexed_db_quota_client_unittest.cc index 0e5b1ee..f9d08be 100644 --- a/content/browser/indexed_db/indexed_db_quota_client_unittest.cc +++ b/content/browser/indexed_db/indexed_db_quota_client_unittest.cc @@ -38,7 +38,7 @@ class IndexedDBQuotaClientTest : public testing::Test { kOriginB("http://host:8000"), kOriginOther("http://other"), usage_(0), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), + weak_factory_(this), message_loop_(MessageLoop::TYPE_IO), db_thread_(BrowserThread::DB, &message_loop_), webkit_thread_(BrowserThread::WEBKIT_DEPRECATED, &message_loop_), diff --git a/content/browser/loader/redirect_to_file_resource_handler.cc b/content/browser/loader/redirect_to_file_resource_handler.cc index f3f81dd..4ab04ea 100644 --- a/content/browser/loader/redirect_to_file_resource_handler.cc +++ b/content/browser/loader/redirect_to_file_resource_handler.cc @@ -58,7 +58,7 @@ RedirectToFileResourceHandler::RedirectToFileResourceHandler( int process_id, ResourceDispatcherHostImpl* host) : LayeredResourceHandler(next_handler.Pass()), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), + weak_factory_(this), host_(host), process_id_(process_id), request_id_(-1), diff --git a/content/browser/loader/render_view_host_tracker.cc b/content/browser/loader/render_view_host_tracker.cc index e394087..2f006e8 100644 --- a/content/browser/loader/render_view_host_tracker.cc +++ b/content/browser/loader/render_view_host_tracker.cc @@ -15,9 +15,9 @@ namespace content { RenderViewHostTracker::RenderViewHostTracker() - : ALLOW_THIS_IN_INITIALIZER_LIST(rvh_created_callback_( + : rvh_created_callback_( base::Bind(&RenderViewHostTracker::RenderViewHostCreated, - base::Unretained(this)))) { + base::Unretained(this))) { DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); RenderViewHost::AddCreatedCallback(rvh_created_callback_); } diff --git a/content/browser/net/view_http_cache_job_factory.cc b/content/browser/net/view_http_cache_job_factory.cc index dad1ea5..70e67e5 100644 --- a/content/browser/net/view_http_cache_job_factory.cc +++ b/content/browser/net/view_http_cache_job_factory.cc @@ -28,10 +28,9 @@ class ViewHttpCacheJob : public net::URLRequestJob { net::NetworkDelegate* network_delegate) : net::URLRequestJob(request, network_delegate), core_(new Core), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), - ALLOW_THIS_IN_INITIALIZER_LIST( - callback_(base::Bind(&ViewHttpCacheJob::OnStartCompleted, - base::Unretained(this)))) { + weak_factory_(this), + callback_(base::Bind(&ViewHttpCacheJob::OnStartCompleted, + base::Unretained(this))) { } // net::URLRequestJob implementation. @@ -53,8 +52,7 @@ class ViewHttpCacheJob : public net::URLRequestJob { public: Core() : data_offset_(0), - ALLOW_THIS_IN_INITIALIZER_LIST(callback_( - base::Bind(&Core::OnIOComplete, this))) { + callback_(base::Bind(&Core::OnIOComplete, this)) { } int Start(const net::URLRequest& request, const base::Closure& callback); diff --git a/content/browser/renderer_host/compositor_impl_android.cc b/content/browser/renderer_host/compositor_impl_android.cc index 28d6e8c..6d4aba1b 100644 --- a/content/browser/renderer_host/compositor_impl_android.cc +++ b/content/browser/renderer_host/compositor_impl_android.cc @@ -121,7 +121,7 @@ CompositorImpl::CompositorImpl(Compositor::Client* client) window_(NULL), surface_id_(0), client_(client), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { DCHECK(client); } diff --git a/content/browser/renderer_host/image_transport_factory.cc b/content/browser/renderer_host/image_transport_factory.cc index b2f09b7..249cb8e 100644 --- a/content/browser/renderer_host/image_transport_factory.cc +++ b/content/browser/renderer_host/image_transport_factory.cc @@ -372,7 +372,7 @@ class GpuProcessTransportFactory public ImageTransportFactory { public: GpuProcessTransportFactory() - : ALLOW_THIS_IN_INITIALIZER_LIST(callback_factory_(this)) { + : callback_factory_(this) { output_surface_proxy_ = new BrowserCompositorOutputSurfaceProxy(); } diff --git a/content/browser/renderer_host/p2p/socket_host_tcp_server.cc b/content/browser/renderer_host/p2p/socket_host_tcp_server.cc index 206a0e4..113eb4d 100644 --- a/content/browser/renderer_host/p2p/socket_host_tcp_server.cc +++ b/content/browser/renderer_host/p2p/socket_host_tcp_server.cc @@ -24,9 +24,9 @@ P2PSocketHostTcpServer::P2PSocketHostTcpServer( IPC::Sender* message_sender, int id) : P2PSocketHost(message_sender, id), socket_(new net::TCPServerSocket(NULL, net::NetLog::Source())), - ALLOW_THIS_IN_INITIALIZER_LIST(accept_callback_( + accept_callback_( base::Bind(&P2PSocketHostTcpServer::OnAccepted, - base::Unretained(this)))) { + base::Unretained(this))) { } P2PSocketHostTcpServer::~P2PSocketHostTcpServer() { diff --git a/content/browser/renderer_host/pepper/pepper_gamepad_host.cc b/content/browser/renderer_host/pepper/pepper_gamepad_host.cc index 1edb1ba7..818bf24 100644 --- a/content/browser/renderer_host/pepper/pepper_gamepad_host.cc +++ b/content/browser/renderer_host/pepper/pepper_gamepad_host.cc @@ -23,7 +23,7 @@ PepperGamepadHost::PepperGamepadHost(BrowserPpapiHost* host, browser_ppapi_host_(host), gamepad_service_(GamepadService::GetInstance()), is_started_(false), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { } PepperGamepadHost::PepperGamepadHost(GamepadService* gamepad_service, @@ -34,7 +34,7 @@ PepperGamepadHost::PepperGamepadHost(GamepadService* gamepad_service, browser_ppapi_host_(host), gamepad_service_(gamepad_service), is_started_(false), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { } PepperGamepadHost::~PepperGamepadHost() { diff --git a/content/browser/renderer_host/pepper/pepper_printing_host.cc b/content/browser/renderer_host/pepper/pepper_printing_host.cc index 959d589..c11939c 100644 --- a/content/browser/renderer_host/pepper/pepper_printing_host.cc +++ b/content/browser/renderer_host/pepper/pepper_printing_host.cc @@ -20,7 +20,7 @@ PepperPrintingHost::PepperPrintingHost( scoped_ptr<PepperPrintSettingsManager> print_settings_manager) : ResourceHost(host, instance, resource), print_settings_manager_(print_settings_manager.Pass()), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_factory_(this) { } PepperPrintingHost::~PepperPrintingHost() { diff --git a/content/browser/renderer_host/quota_dispatcher_host.cc b/content/browser/renderer_host/quota_dispatcher_host.cc index 0aa776e..fd297e7 100644 --- a/content/browser/renderer_host/quota_dispatcher_host.cc +++ b/content/browser/renderer_host/quota_dispatcher_host.cc @@ -60,7 +60,7 @@ class QuotaDispatcherHost::QueryUsageAndQuotaDispatcher QuotaDispatcherHost* dispatcher_host, int request_id) : RequestDispatcher(dispatcher_host, request_id), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {} + weak_factory_(this) {} virtual ~QueryUsageAndQuotaDispatcher() {} void QueryStorageUsageAndQuota(const GURL& origin, StorageType type) { @@ -104,7 +104,7 @@ class QuotaDispatcherHost::RequestQuotaDispatcher current_quota_(0), requested_quota_(requested_quota), render_view_id_(render_view_id), - weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {} + weak_factory_(this) {} virtual ~RequestQuotaDispatcher() {} void Start() { diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc index c505f90..b0f7984 100644 --- a/content/browser/renderer_host/render_process_host_impl.cc +++ b/content/browser/renderer_host/render_process_host_impl.cc @@ -383,9 +383,9 @@ RenderProcessHostImpl::RenderProcessHostImpl( pending_views_(0), visible_widgets_(0), backgrounded_(true), - ALLOW_THIS_IN_INITIALIZER_LIST(cached_dibs_cleaner_( - FROM_HERE, base::TimeDelta::FromSeconds(5), - this, &RenderProcessHostImpl::ClearTransportDIBCache)), + cached_dibs_cleaner_( + FROM_HERE, base::TimeDelta::FromSeconds(5), + this, &RenderProcessHostImpl::ClearTransportDIBCache), is_initialized_(false), id_(ChildProcessHostImpl::GenerateChildProcessUniqueId()), browser_context_(browser_context), diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc index 6fc1ad7..036e641 100644 --- a/content/browser/renderer_host/render_widget_host_impl.cc +++ b/content/browser/renderer_host/render_widget_host_impl.cc @@ -165,7 +165,7 @@ RenderWidgetHostImpl::RenderWidgetHostImpl(RenderWidgetHostDelegate* delegate, pending_mouse_lock_request_(false), allow_privileged_mouse_lock_(false), has_touch_handler_(false), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), + weak_factory_(this), touch_event_queue_(new TouchEventQueue(this)), gesture_event_filter_(new GestureEventFilter(this)) { CHECK(delegate_); diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc index a3e04c1..f39e30b 100644 --- a/content/browser/renderer_host/render_widget_host_view_android.cc +++ b/content/browser/renderer_host/render_widget_host_view_android.cc @@ -76,7 +76,7 @@ RenderWidgetHostViewAndroid::RenderWidgetHostViewAndroid( : host_(widget_host), is_layer_attached_(true), content_view_core_(NULL), - ime_adapter_android_(ALLOW_THIS_IN_INITIALIZER_LIST(this)), + ime_adapter_android_(this), cached_background_color_(SK_ColorWHITE), texture_id_in_layer_(0) { if (CompositorImpl::UsesDirectGL()) { diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc index e6b66f7..273e86a 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura.cc @@ -621,7 +621,7 @@ class RenderWidgetHostViewAura::ResizeLock { RenderWidgetHostViewAura::RenderWidgetHostViewAura(RenderWidgetHost* host) : host_(RenderWidgetHostImpl::From(host)), - ALLOW_THIS_IN_INITIALIZER_LIST(window_(new aura::Window(this))), + window_(new aura::Window(this)), in_shutdown_(false), is_fullscreen_(false), popup_parent_host_view_(NULL), diff --git a/content/browser/renderer_host/render_widget_host_view_win.cc b/content/browser/renderer_host/render_widget_host_view_win.cc index 6b2c3f08..9dacbe0 100644 --- a/content/browser/renderer_host/render_widget_host_view_win.cc +++ b/content/browser/renderer_host/render_widget_host_view_win.cc @@ -406,13 +406,11 @@ RenderWidgetHostViewWin::RenderWidgetHostViewWin(RenderWidgetHost* widget) is_fullscreen_(false), ignore_mouse_movement_(true), composition_range_(ui::Range::InvalidRange()), - ALLOW_THIS_IN_INITIALIZER_LIST( - touch_state_(new WebTouchState(this))), + touch_state_(new WebTouchState(this)), pointer_down_context_(false), last_touch_location_(-1, -1), touch_events_enabled_(false), - ALLOW_THIS_IN_INITIALIZER_LIST( - gesture_recognizer_(ui::GestureRecognizer::Create(this))) { + gesture_recognizer_(ui::GestureRecognizer::Create(this)) { render_widget_host_->SetView(this); registrar_.Add(this, NOTIFICATION_RENDERER_PROCESS_TERMINATED, diff --git a/content/browser/speech/speech_recognition_manager_impl.cc b/content/browser/speech/speech_recognition_manager_impl.cc index e713e45..d8faf9d 100644 --- a/content/browser/speech/speech_recognition_manager_impl.cc +++ b/content/browser/speech/speech_recognition_manager_impl.cc @@ -60,7 +60,7 @@ SpeechRecognitionManagerImpl::SpeechRecognitionManagerImpl() is_dispatching_event_(false), delegate_(GetContentClient()->browser()-> GetSpeechRecognitionManagerDelegate()), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { DCHECK(!g_speech_recognition_manager_impl); g_speech_recognition_manager_impl = this; } diff --git a/content/browser/storage_partition_impl_unittest.cc b/content/browser/storage_partition_impl_unittest.cc index 6e26c3c..8b68ef5 100644 --- a/content/browser/storage_partition_impl_unittest.cc +++ b/content/browser/storage_partition_impl_unittest.cc @@ -20,9 +20,8 @@ namespace { class TestClosureCallback { public: TestClosureCallback() - : ALLOW_THIS_IN_INITIALIZER_LIST(callback_( - base::Bind(&TestClosureCallback::StopWaiting, - base::Unretained(this)))) { + : callback_(base::Bind( + &TestClosureCallback::StopWaiting, base::Unretained(this))) { } void WaitForResult() { diff --git a/content/browser/streams/stream.cc b/content/browser/streams/stream.cc index d77afd2a..8a926a6 100644 --- a/content/browser/streams/stream.cc +++ b/content/browser/streams/stream.cc @@ -33,7 +33,7 @@ Stream::Stream(StreamRegistry* registry, read_observer_(NULL), write_observer_(write_observer), stream_handle_(NULL), - weak_ptr_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { + weak_ptr_factory_(this) { CreateByteStream(base::MessageLoopProxy::current(), base::MessageLoopProxy::current(), kDeferSizeThreshold, diff --git a/content/browser/streams/stream_url_request_job.cc b/content/browser/streams/stream_url_request_job.cc index 8f94606..85e1a6d 100644 --- a/content/browser/streams/stream_url_request_job.cc +++ b/content/browser/streams/stream_url_request_job.cc @@ -37,7 +37,7 @@ StreamURLRequestJob::StreamURLRequestJob( net::NetworkDelegate* network_delegate, scoped_refptr<Stream> stream) : net::URLRequestJob(request, network_delegate), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)), + weak_factory_(this), stream_(stream), headers_set_(false), pending_buffer_size_(0), diff --git a/content/browser/web_contents/interstitial_page_impl.cc b/content/browser/web_contents/interstitial_page_impl.cc index 72d0fc9..0a5fa03 100644 --- a/content/browser/web_contents/interstitial_page_impl.cc +++ b/content/browser/web_contents/interstitial_page_impl.cc @@ -148,11 +148,10 @@ InterstitialPageImpl::InterstitialPageImpl(WebContents* web_contents, should_revert_web_contents_title_(false), web_contents_was_loading_(false), resource_dispatcher_host_notified_(false), - ALLOW_THIS_IN_INITIALIZER_LIST(rvh_delegate_view_( - new InterstitialPageRVHDelegateView(this))), + rvh_delegate_view_(new InterstitialPageRVHDelegateView(this)), create_view_(true), delegate_(delegate), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) { + weak_ptr_factory_(this) { InitInterstitialPageMap(); // It would be inconsistent to create an interstitial with no new navigation // (which is the case when the interstitial was triggered by a sub-resource on diff --git a/content/browser/web_contents/navigation_controller_impl.cc b/content/browser/web_contents/navigation_controller_impl.cc index 6985360..6051efe 100644 --- a/content/browser/web_contents/navigation_controller_impl.cc +++ b/content/browser/web_contents/navigation_controller_impl.cc @@ -213,13 +213,12 @@ NavigationControllerImpl::NavigationControllerImpl( transient_entry_index_(-1), web_contents_(web_contents), max_restored_page_id_(-1), - ALLOW_THIS_IN_INITIALIZER_LIST(ssl_manager_(this)), + ssl_manager_(this), needs_reload_(false), is_initial_navigation_(true), pending_reload_(NO_RELOAD), get_timestamp_callback_(base::Bind(&base::Time::Now)), - ALLOW_THIS_IN_INITIALIZER_LIST( - screenshot_manager_(new WebContentsScreenshotManager(this))) { + screenshot_manager_(new WebContentsScreenshotManager(this)) { DCHECK(browser_context_); } diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc index da5968f..0e678f6 100644 --- a/content/browser/web_contents/web_contents_impl.cc +++ b/content/browser/web_contents/web_contents_impl.cc @@ -281,13 +281,13 @@ WebContentsImpl::WebContentsImpl( BrowserContext* browser_context, WebContentsImpl* opener) : delegate_(NULL), - ALLOW_THIS_IN_INITIALIZER_LIST(controller_(this, browser_context)), + controller_(this, browser_context), render_view_host_delegate_view_(NULL), opener_(opener), #if defined(OS_WIN) && defined(USE_AURA) accessible_parent_(NULL), #endif - ALLOW_THIS_IN_INITIALIZER_LIST(render_manager_(this, this, this)), + render_manager_(this, this, this), is_loading_(false), crashed_status_(base::TERMINATION_STATUS_STILL_RUNNING), crashed_error_code_(0), diff --git a/content/browser/webui/url_data_manager_backend.cc b/content/browser/webui/url_data_manager_backend.cc index 1085811..2fd411c 100644 --- a/content/browser/webui/url_data_manager_backend.cc +++ b/content/browser/webui/url_data_manager_backend.cc @@ -214,7 +214,7 @@ URLRequestChromeJob::URLRequestChromeJob(net::URLRequest* request, deny_xframe_options_(true), is_incognito_(is_incognito), backend_(backend), - ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { + weak_factory_(this) { DCHECK(backend); } diff --git a/content/browser/webui/web_ui_data_source_impl.cc b/content/browser/webui/web_ui_data_source_impl.cc index 4ec9e80..7ca34d2 100644 --- a/content/browser/webui/web_ui_data_source_impl.cc +++ b/content/browser/webui/web_ui_data_source_impl.cc @@ -73,7 +73,7 @@ class WebUIDataSourceImpl::InternalDataSource : public URLDataSource { WebUIDataSourceImpl::WebUIDataSourceImpl(const std::string& source_name) : URLDataSourceImpl( source_name, - new InternalDataSource(ALLOW_THIS_IN_INITIALIZER_LIST(this))), + new InternalDataSource(this)), source_name_(source_name), default_resource_(-1), json_js_format_v2_(false), |