diff --git a/atom.gyp b/atom.gyp index 917f20a30..e67ed87ae 100644 --- a/atom.gyp +++ b/atom.gyp @@ -40,31 +40,28 @@ 'defines': [ 'USING_CEF_SHARED', ], - 'include_dirs': [ - '.', - 'tests', - ], + 'include_dirs': [ '.' ], 'sources': [ '<@(includes_common)', '<@(includes_wrapper)', - 'tests/cefclient/client_handler.cpp', - 'tests/cefclient/client_handler.h', - 'tests/cefclient/util.h', + 'atom/client_handler.cpp', + 'atom/client_handler.h', + 'atom/util.h', ], 'mac_bundle_resources': [ - 'tests/cefclient/mac/cefclient.icns', - 'tests/cefclient/mac/English.lproj/InfoPlist.strings', - 'tests/cefclient/mac/English.lproj/MainMenu.xib', - 'tests/cefclient/mac/Info.plist', + 'atom/mac/cefclient.icns', + 'atom/mac/English.lproj/InfoPlist.strings', + 'atom/mac/English.lproj/MainMenu.xib', + 'atom/mac/Info.plist', ], 'mac_bundle_resources!': [ # TODO(mark): Come up with a fancier way to do this (mac_info_plist?) # that automatically sets the correct INFOPLIST_FILE setting and adds # the file to a source group. - 'tests/cefclient/mac/Info.plist', + 'atom/mac/Info.plist', ], 'xcode_settings': { - 'INFOPLIST_FILE': 'tests/cefclient/mac/Info.plist', + 'INFOPLIST_FILE': 'atom/mac/Info.plist', # Necessary to avoid an "install_name_tool: changing install names or # rpaths can't be redone" error. 'OTHER_LDFLAGS': ['-Wl,-headerpad_max_install_names'], @@ -179,10 +176,10 @@ ], }, 'sources': [ - 'tests/cefclient/main_mac.mm', - 'tests/cefclient/cefclient_mac.h', - 'tests/cefclient/cefclient_mac.mm', - 'tests/cefclient/client_handler_mac.mm', + 'atom/main_mac.mm', + 'atom/cefclient_mac.h', + 'atom/cefclient_mac.mm', + 'atom/client_handler_mac.mm', 'include/cef_application_mac.h', 'include/internal/cef_mac.h', 'include/internal/cef_types_mac.h', @@ -213,9 +210,7 @@ 'defines': [ 'USING_CEF_SHARED', ], - 'include_dirs': [ - '.', - ], + 'include_dirs': [ '.' ], 'sources': [ '<@(includes_common)', '<@(includes_capi)', @@ -252,29 +247,24 @@ 'USING_CEF_SHARED', 'PROCESS_HELPER_APP', ], - 'include_dirs': [ - '.', - # cefclient includes are relative to the tests directory to make - # creation of binary releases easier. - 'tests' - ], + 'include_dirs': [ '.' ], 'link_settings': { 'libraries': [ '$(SDKROOT)/System/Library/Frameworks/AppKit.framework', ], }, 'sources': [ - 'tests/cefclient/client_handler_mac.mm', - 'tests/cefclient/process_helper_mac.cpp', - 'tests/cefclient/client_handler.cpp', - 'tests/cefclient/client_handler.h', - 'tests/cefclient/util.h', + 'atom/client_handler_mac.mm', + 'atom/process_helper_mac.cpp', + 'atom/client_handler.cpp', + 'atom/client_handler.h', + 'atom/util.h', ], # TODO(mark): Come up with a fancier way to do this. It should only # be necessary to list helper-Info.plist once, not the three times it # is listed here. 'mac_bundle_resources!': [ - 'tests/cefclient/mac/helper-Info.plist', + 'atom/mac/helper-Info.plist', ], # TODO(mark): For now, don't put any resources into this app. Its # resources directory will be a symbolic link to the browser app's @@ -283,7 +273,7 @@ ['exclude', '.*'], ], 'xcode_settings': { - 'INFOPLIST_FILE': 'tests/cefclient/mac/helper-Info.plist', + 'INFOPLIST_FILE': 'atom/mac/helper-Info.plist', # Necessary to avoid an "install_name_tool: changing install names or # rpaths can't be redone" error. 'OTHER_LDFLAGS': ['-Wl,-headerpad_max_install_names'], diff --git a/tests/cefclient/cefclient.rc b/atom/cefclient.rc similarity index 96% rename from tests/cefclient/cefclient.rc rename to atom/cefclient.rc index c56c72659..14b3f9491 100644 --- a/tests/cefclient/cefclient.rc +++ b/atom/cefclient.rc @@ -1,172 +1,172 @@ -// Microsoft Visual C++ generated resource script. -// -#include "resource.h" - -#define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 2 resource. -// -#define APSTUDIO_HIDDEN_SYMBOLS -#include "windows.h" -#undef APSTUDIO_HIDDEN_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -#undef APSTUDIO_READONLY_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -// English (U.S.) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 -LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US -#pragma code_page(1252) -#endif //_WIN32 - -///////////////////////////////////////////////////////////////////////////// -// -// Binary -// - -IDS_BINDING BINARY "res\\binding.html" -IDS_DIALOGS BINARY "res\\dialogs.html" -IDS_LOGO BINARY "res\\logo.png" -IDS_LOGOBALL BINARY "res\\logoball.png" -IDS_LOCALSTORAGE BINARY "res\\localstorage.html" -IDS_XMLHTTPREQUEST BINARY "res\\xmlhttprequest.html" -IDS_DOMACCESS BINARY "res\\domaccess.html" - -///////////////////////////////////////////////////////////////////////////// -// -// Icon -// - -// Icon with lowest ID value placed first to ensure application icon -// remains consistent on all systems. -IDI_CEFCLIENT ICON "res\cefclient.ico" -IDI_SMALL ICON "res\small.ico" - -///////////////////////////////////////////////////////////////////////////// -// -// Menu -// - -IDC_CEFCLIENT MENU -BEGIN - POPUP "&File" - BEGIN - MENUITEM "E&xit", IDM_EXIT - END - POPUP "&Help" - BEGIN - MENUITEM "&About ...", IDM_ABOUT - END - POPUP "Tests" - BEGIN - MENUITEM "Get Source", ID_TESTS_GETSOURCE - MENUITEM "Get Text", ID_TESTS_GETTEXT - MENUITEM "Popup Window", ID_TESTS_POPUP - MENUITEM "Request", ID_TESTS_REQUEST - MENUITEM "Scheme Handler", ID_TESTS_SCHEME_HANDLER - MENUITEM "JavaScript Binding", ID_TESTS_BINDING - MENUITEM "JavaScript Dialogs", ID_TESTS_DIALOGS - MENUITEM "Plugin Info", ID_TESTS_PLUGIN_INFO - MENUITEM "DOM Access", ID_TESTS_DOM_ACCESS - MENUITEM "Local Storage", ID_TESTS_LOCALSTORAGE - MENUITEM "XMLHttpRequest", ID_TESTS_XMLHTTPREQUEST - MENUITEM "Accelerated 2D Canvas", ID_TESTS_ACCELERATED2DCANVAS - MENUITEM "Accelerated Layers", ID_TESTS_ACCELERATEDLAYERS - MENUITEM "WebGL", ID_TESTS_WEBGL - MENUITEM "HTML5 Video", ID_TESTS_HTML5VIDEO - MENUITEM "Drag && Drop", ID_TESTS_DRAGDROP - MENUITEM "Geolocation", ID_TESTS_GEOLOCATION - MENUITEM "Zoom In", ID_TESTS_ZOOM_IN - MENUITEM "Zoom Out", ID_TESTS_ZOOM_OUT - MENUITEM "Zoom Reset", ID_TESTS_ZOOM_RESET - END -END - - -///////////////////////////////////////////////////////////////////////////// -// -// Accelerator -// - -IDC_CEFCLIENT ACCELERATORS -BEGIN - "?", IDM_ABOUT, ASCII, ALT - "/", IDM_ABOUT, ASCII, ALT -END - - -///////////////////////////////////////////////////////////////////////////// -// -// Dialog -// - -IDD_ABOUTBOX DIALOG 22, 17, 230, 75 -STYLE DS_SETFONT | DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "About" -FONT 8, "System" -BEGIN - ICON IDI_CEFCLIENT,IDC_MYICON,14,9,16,16 - LTEXT "cefclient Version 1.0",IDC_STATIC,49,10,119,8,SS_NOPREFIX - LTEXT "Copyright (C) 2008",IDC_STATIC,49,20,119,8 - DEFPUSHBUTTON "OK",IDOK,195,6,30,11,WS_GROUP -END - - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE -BEGIN - "resource.h\0" -END - -2 TEXTINCLUDE -BEGIN - "#define APSTUDIO_HIDDEN_SYMBOLS\r\n" - "#include ""windows.h""\r\n" - "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n" - "\0" -END - -3 TEXTINCLUDE -BEGIN - "\r\n" - "\0" -END - -#endif // APSTUDIO_INVOKED - - -///////////////////////////////////////////////////////////////////////////// -// -// String Table -// - -STRINGTABLE -BEGIN - IDS_APP_TITLE "cefclient" - IDC_CEFCLIENT "CEFCLIENT" -END - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - - -#ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// Generated from the TEXTINCLUDE 3 resource. -// - - -///////////////////////////////////////////////////////////////////////////// -#endif // not APSTUDIO_INVOKED - +// Microsoft Visual C++ generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#define APSTUDIO_HIDDEN_SYMBOLS +#include "windows.h" +#undef APSTUDIO_HIDDEN_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// English (U.S.) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US +#pragma code_page(1252) +#endif //_WIN32 + +///////////////////////////////////////////////////////////////////////////// +// +// Binary +// + +IDS_BINDING BINARY "res\\binding.html" +IDS_DIALOGS BINARY "res\\dialogs.html" +IDS_LOGO BINARY "res\\logo.png" +IDS_LOGOBALL BINARY "res\\logoball.png" +IDS_LOCALSTORAGE BINARY "res\\localstorage.html" +IDS_XMLHTTPREQUEST BINARY "res\\xmlhttprequest.html" +IDS_DOMACCESS BINARY "res\\domaccess.html" + +///////////////////////////////////////////////////////////////////////////// +// +// Icon +// + +// Icon with lowest ID value placed first to ensure application icon +// remains consistent on all systems. +IDI_CEFCLIENT ICON "res\cefclient.ico" +IDI_SMALL ICON "res\small.ico" + +///////////////////////////////////////////////////////////////////////////// +// +// Menu +// + +IDC_CEFCLIENT MENU +BEGIN + POPUP "&File" + BEGIN + MENUITEM "E&xit", IDM_EXIT + END + POPUP "&Help" + BEGIN + MENUITEM "&About ...", IDM_ABOUT + END + POPUP "Tests" + BEGIN + MENUITEM "Get Source", ID_TESTS_GETSOURCE + MENUITEM "Get Text", ID_TESTS_GETTEXT + MENUITEM "Popup Window", ID_TESTS_POPUP + MENUITEM "Request", ID_TESTS_REQUEST + MENUITEM "Scheme Handler", ID_TESTS_SCHEME_HANDLER + MENUITEM "JavaScript Binding", ID_TESTS_BINDING + MENUITEM "JavaScript Dialogs", ID_TESTS_DIALOGS + MENUITEM "Plugin Info", ID_TESTS_PLUGIN_INFO + MENUITEM "DOM Access", ID_TESTS_DOM_ACCESS + MENUITEM "Local Storage", ID_TESTS_LOCALSTORAGE + MENUITEM "XMLHttpRequest", ID_TESTS_XMLHTTPREQUEST + MENUITEM "Accelerated 2D Canvas", ID_TESTS_ACCELERATED2DCANVAS + MENUITEM "Accelerated Layers", ID_TESTS_ACCELERATEDLAYERS + MENUITEM "WebGL", ID_TESTS_WEBGL + MENUITEM "HTML5 Video", ID_TESTS_HTML5VIDEO + MENUITEM "Drag && Drop", ID_TESTS_DRAGDROP + MENUITEM "Geolocation", ID_TESTS_GEOLOCATION + MENUITEM "Zoom In", ID_TESTS_ZOOM_IN + MENUITEM "Zoom Out", ID_TESTS_ZOOM_OUT + MENUITEM "Zoom Reset", ID_TESTS_ZOOM_RESET + END +END + + +///////////////////////////////////////////////////////////////////////////// +// +// Accelerator +// + +IDC_CEFCLIENT ACCELERATORS +BEGIN + "?", IDM_ABOUT, ASCII, ALT + "/", IDM_ABOUT, ASCII, ALT +END + + +///////////////////////////////////////////////////////////////////////////// +// +// Dialog +// + +IDD_ABOUTBOX DIALOG 22, 17, 230, 75 +STYLE DS_SETFONT | DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "About" +FONT 8, "System" +BEGIN + ICON IDI_CEFCLIENT,IDC_MYICON,14,9,16,16 + LTEXT "cefclient Version 1.0",IDC_STATIC,49,10,119,8,SS_NOPREFIX + LTEXT "Copyright (C) 2008",IDC_STATIC,49,20,119,8 + DEFPUSHBUTTON "OK",IDOK,195,6,30,11,WS_GROUP +END + + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE +BEGIN + "#define APSTUDIO_HIDDEN_SYMBOLS\r\n" + "#include ""windows.h""\r\n" + "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n" + "\0" +END + +3 TEXTINCLUDE +BEGIN + "\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// +// String Table +// + +STRINGTABLE +BEGIN + IDS_APP_TITLE "cefclient" + IDC_CEFCLIENT "CEFCLIENT" +END + +#endif // English (U.S.) resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// + + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED + diff --git a/tests/cefclient/cefclient_gtk.cpp b/atom/cefclient_gtk.cpp similarity index 100% rename from tests/cefclient/cefclient_gtk.cpp rename to atom/cefclient_gtk.cpp diff --git a/tests/cefclient/cefclient_mac.h b/atom/cefclient_mac.h similarity index 100% rename from tests/cefclient/cefclient_mac.h rename to atom/cefclient_mac.h diff --git a/tests/cefclient/cefclient_mac.mm b/atom/cefclient_mac.mm similarity index 98% rename from tests/cefclient/cefclient_mac.mm rename to atom/cefclient_mac.mm index fd5a244c6..6ac3f19a4 100644 --- a/tests/cefclient/cefclient_mac.mm +++ b/atom/cefclient_mac.mm @@ -5,8 +5,8 @@ #include "include/cef_browser.h" #include "include/cef_frame.h" #include "include/cef_runnable.h" -#include "cefclient/client_handler.h" -#include "cefclient/cefclient_mac.h" +#include "atom/client_handler.h" +#include "atom/cefclient_mac.h" // The global ClientHandler reference. extern CefRefPtr g_handler; diff --git a/tests/cefclient/cefclient_win.cpp b/atom/cefclient_win.cpp similarity index 100% rename from tests/cefclient/cefclient_win.cpp rename to atom/cefclient_win.cpp diff --git a/tests/cefclient/client_handler.cpp b/atom/client_handler.cpp similarity index 99% rename from tests/cefclient/client_handler.cpp rename to atom/client_handler.cpp index eb5ca54c3..844b6861c 100644 --- a/tests/cefclient/client_handler.cpp +++ b/atom/client_handler.cpp @@ -2,7 +2,7 @@ // reserved. Use of this source code is governed by a BSD-style license that // can be found in the LICENSE file. -#include "cefclient/client_handler.h" +#include "atom/client_handler.h" #include #include #include diff --git a/tests/cefclient/client_handler.h b/atom/client_handler.h similarity index 99% rename from tests/cefclient/client_handler.h rename to atom/client_handler.h index cd691c9d3..11dcbb37e 100644 --- a/tests/cefclient/client_handler.h +++ b/atom/client_handler.h @@ -10,7 +10,7 @@ #include #include #include "include/cef_client.h" -#include "cefclient/util.h" +#include "atom/util.h" // Define this value to redirect all popup URLs to the main application browser diff --git a/tests/cefclient/client_handler_gtk.cpp b/atom/client_handler_gtk.cpp similarity index 100% rename from tests/cefclient/client_handler_gtk.cpp rename to atom/client_handler_gtk.cpp diff --git a/tests/cefclient/client_handler_mac.mm b/atom/client_handler_mac.mm similarity index 96% rename from tests/cefclient/client_handler_mac.mm rename to atom/client_handler_mac.mm index 3a405aeae..d1ddffc92 100644 --- a/tests/cefclient/client_handler_mac.mm +++ b/atom/client_handler_mac.mm @@ -4,7 +4,7 @@ #import -#include "cefclient/client_handler.h" +#include "atom/client_handler.h" #include "include/cef_browser.h" #include "include/cef_frame.h" diff --git a/tests/cefclient/client_handler_win.cpp b/atom/client_handler_win.cpp similarity index 100% rename from tests/cefclient/client_handler_win.cpp rename to atom/client_handler_win.cpp diff --git a/tests/cefclient/mac/English.lproj/InfoPlist.strings b/atom/mac/English.lproj/InfoPlist.strings similarity index 100% rename from tests/cefclient/mac/English.lproj/InfoPlist.strings rename to atom/mac/English.lproj/InfoPlist.strings diff --git a/tests/cefclient/mac/English.lproj/MainMenu.xib b/atom/mac/English.lproj/MainMenu.xib similarity index 100% rename from tests/cefclient/mac/English.lproj/MainMenu.xib rename to atom/mac/English.lproj/MainMenu.xib diff --git a/tests/cefclient/mac/Info.plist b/atom/mac/Info.plist similarity index 100% rename from tests/cefclient/mac/Info.plist rename to atom/mac/Info.plist diff --git a/tests/cefclient/mac/cefclient.icns b/atom/mac/cefclient.icns similarity index 100% rename from tests/cefclient/mac/cefclient.icns rename to atom/mac/cefclient.icns diff --git a/tests/cefclient/mac/helper-Info.plist b/atom/mac/helper-Info.plist similarity index 100% rename from tests/cefclient/mac/helper-Info.plist rename to atom/mac/helper-Info.plist diff --git a/tests/cefclient/main_mac.mm b/atom/main_mac.mm similarity index 93% rename from tests/cefclient/main_mac.mm rename to atom/main_mac.mm index 8748a7b2a..15673945a 100644 --- a/tests/cefclient/main_mac.mm +++ b/atom/main_mac.mm @@ -5,8 +5,8 @@ #include "include/cef_browser.h" #include "include/cef_frame.h" #include "include/cef_runnable.h" -#include "cefclient/client_handler.h" -#include "cefclient/cefclient_mac.h" +#include "atom/client_handler.h" +#include "atom/cefclient_mac.h" int main(int argc, char* argv[]) { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; diff --git a/tests/cefclient/process_helper_mac.cpp b/atom/process_helper_mac.cpp similarity index 100% rename from tests/cefclient/process_helper_mac.cpp rename to atom/process_helper_mac.cpp diff --git a/tests/cefclient/res/cefclient.ico b/atom/res/cefclient.ico similarity index 100% rename from tests/cefclient/res/cefclient.ico rename to atom/res/cefclient.ico diff --git a/tests/cefclient/res/small.ico b/atom/res/small.ico similarity index 100% rename from tests/cefclient/res/small.ico rename to atom/res/small.ico diff --git a/tests/cefclient/util.h b/atom/util.h similarity index 100% rename from tests/cefclient/util.h rename to atom/util.h