Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(394)

Side by Side Diff: chrome_frame/chrome_tab.cc

Issue 9702021: Unconditionally send Chrome and Chrome Frame events through ETW machinery. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/test/logging/win/file_logger.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // chrome_tab.cc : Implementation of DLL Exports. 5 // chrome_tab.cc : Implementation of DLL Exports.
6 6
7 // Need to include this before the ATL headers below. 7 // Need to include this before the ATL headers below.
8 #include "chrome_frame/chrome_tab.h" 8 #include "chrome_frame/chrome_tab.h"
9 9
10 #include <atlsecurity.h> 10 #include <atlsecurity.h>
(...skipping 10 matching lines...) Expand all
21 #include "base/string16.h" 21 #include "base/string16.h"
22 #include "base/string_number_conversions.h" 22 #include "base/string_number_conversions.h"
23 #include "base/string_piece.h" 23 #include "base/string_piece.h"
24 #include "base/string_util.h" 24 #include "base/string_util.h"
25 #include "base/sys_string_conversions.h" 25 #include "base/sys_string_conversions.h"
26 #include "base/utf_string_conversions.h" 26 #include "base/utf_string_conversions.h"
27 #include "base/win/registry.h" 27 #include "base/win/registry.h"
28 #include "base/win/windows_version.h" 28 #include "base/win/windows_version.h"
29 #include "chrome/common/chrome_constants.h" 29 #include "chrome/common/chrome_constants.h"
30 #include "chrome/common/chrome_switches.h" 30 #include "chrome/common/chrome_switches.h"
31 #include "chrome/common/env_vars.h"
32 #include "chrome/installer/util/google_update_settings.h" 31 #include "chrome/installer/util/google_update_settings.h"
33 #include "chrome_frame/bho.h" 32 #include "chrome_frame/bho.h"
34 #include "chrome_frame/chrome_active_document.h" 33 #include "chrome_frame/chrome_active_document.h"
35 #include "chrome_frame/chrome_frame_activex.h" 34 #include "chrome_frame/chrome_frame_activex.h"
36 #include "chrome_frame/chrome_frame_automation.h" 35 #include "chrome_frame/chrome_frame_automation.h"
37 #include "chrome_frame/chrome_frame_reporting.h" 36 #include "chrome_frame/chrome_frame_reporting.h"
38 #include "chrome_frame/chrome_launcher_utils.h" 37 #include "chrome_frame/chrome_launcher_utils.h"
39 #include "chrome_frame/chrome_protocol.h" 38 #include "chrome_frame/chrome_protocol.h"
40 #include "chrome_frame/dll_redirector.h" 39 #include "chrome_frame/dll_redirector.h"
41 #include "chrome_frame/exception_barrier.h" 40 #include "chrome_frame/exception_barrier.h"
(...skipping 807 matching lines...) Expand 10 before | Expand all | Expand 10 after
849 if (!dll_redirector->RegisterAsFirstCFModule()) { 848 if (!dll_redirector->RegisterAsFirstCFModule()) {
850 // Someone else was here first, try and get a pointer to their 849 // Someone else was here first, try and get a pointer to their
851 // DllGetClassObject export: 850 // DllGetClassObject export:
852 g_dll_get_class_object_redir_ptr = 851 g_dll_get_class_object_redir_ptr =
853 dll_redirector->GetDllGetClassObjectPtr(); 852 dll_redirector->GetDllGetClassObjectPtr();
854 DCHECK(g_dll_get_class_object_redir_ptr != NULL) 853 DCHECK(g_dll_get_class_object_redir_ptr != NULL)
855 << "Found CF module with no DllGetClassObject export."; 854 << "Found CF module with no DllGetClassObject export.";
856 } 855 }
857 856
858 // Enable trace control and transport through event tracing for Windows. 857 // Enable trace control and transport through event tracing for Windows.
859 if (::GetEnvironmentVariable(ASCIIToWide(env_vars::kEtwLogging).c_str(), 858 logging::LogEventProvider::Initialize(kChromeFrameProvider);
860 NULL, 0)) {
861 logging::LogEventProvider::Initialize(kChromeFrameProvider);
862 }
863 859
864 // Initialize the field test infrastructure. Must be done somewhere that 860 // Initialize the field test infrastructure. Must be done somewhere that
865 // can only get called once. For Chrome Frame, that is here. 861 // can only get called once. For Chrome Frame, that is here.
866 g_field_trial_list = new base::FieldTrialList( 862 g_field_trial_list = new base::FieldTrialList(
867 MetricsService::GetClientID()); 863 MetricsService::GetClientID());
868 } else if (reason == DLL_PROCESS_DETACH) { 864 } else if (reason == DLL_PROCESS_DETACH) {
869 delete g_field_trial_list; 865 delete g_field_trial_list;
870 g_field_trial_list = NULL; 866 g_field_trial_list = NULL;
871 867
872 DllRedirector* dll_redirector = DllRedirector::GetInstance(); 868 DllRedirector* dll_redirector = DllRedirector::GetInstance();
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
942 HRESULT hr = CustomRegistration(ALL, FALSE, false); 938 HRESULT hr = CustomRegistration(ALL, FALSE, false);
943 return hr; 939 return hr;
944 } 940 }
945 941
946 // Object entries go here instead of with each object, so that we can move 942 // Object entries go here instead of with each object, so that we can move
947 // the objects to a lib. Also reduces magic. 943 // the objects to a lib. Also reduces magic.
948 OBJECT_ENTRY_AUTO(CLSID_ChromeFrameBHO, Bho) 944 OBJECT_ENTRY_AUTO(CLSID_ChromeFrameBHO, Bho)
949 OBJECT_ENTRY_AUTO(__uuidof(ChromeActiveDocument), ChromeActiveDocument) 945 OBJECT_ENTRY_AUTO(__uuidof(ChromeActiveDocument), ChromeActiveDocument)
950 OBJECT_ENTRY_AUTO(__uuidof(ChromeFrame), ChromeFrameActivex) 946 OBJECT_ENTRY_AUTO(__uuidof(ChromeFrame), ChromeFrameActivex)
951 OBJECT_ENTRY_AUTO(__uuidof(ChromeProtocol), ChromeProtocol) 947 OBJECT_ENTRY_AUTO(__uuidof(ChromeProtocol), ChromeProtocol)
OLDNEW
« no previous file with comments | « chrome/test/logging/win/file_logger.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698