2010-10-28 Ivan Krstić <ike@apple.com>
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 28 Oct 2010 07:14:41 +0000 (07:14 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 28 Oct 2010 07:14:41 +0000 (07:14 +0000)
        Reviewed by Mark Rowe.

        Remove unused experimental proxied panel interface.
        <rdar://problem/7237059>

        * WebCore.exp.in:
        * platform/mac/WebCoreSystemInterface.h:
        * platform/mac/WebCoreSystemInterface.mm:
2010-10-28  Ivan Krstić  <ike@apple.com>

        Reviewed by Mark Rowe.

        Remove unused experimental proxied panel interface.
        <rdar://problem/7237059>

        * Plugins/Hosted/NetscapePluginHostManager.h:
        * Plugins/Hosted/NetscapePluginHostManager.mm:
        (WebKit::NetscapePluginHostManager::hostForPlugin):
        (WebKit::NetscapePluginHostManager::spawnPluginHost):
        (WebKit::NetscapePluginHostManager::instantiatePlugin):
        * Plugins/Hosted/NetscapePluginHostProxy.mm:
        * Plugins/Hosted/WebKitPluginClient.defs:
        * Plugins/Hosted/WebKitPluginHost.defs:
        * WebCoreSupport/WebSystemInterface.mm:
        (InitWebCoreSystemInterface):
        * WebView/WebPreferenceKeysPrivate.h:
        * WebView/WebPreferences.mm:
        (+[WebPreferences initialize]):
        * WebView/WebPreferencesPrivate.h:
2010-10-28  Ivan Krstić  <ike@apple.com>

        Reviewed by Mark Rowe.

        Remove unused experimental proxied panel interface.
        <rdar://problem/7237059>

        * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
        (InitWebCoreSystemInterface):
2010-10-28  Ivan Krstić  <ike@apple.com>

        Reviewed by Mark Rowe.

        Remove unused experimental proxied panel interface.
        <rdar://problem/7237059>

        * WebKitSystemInterface.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@70751 268f45cc-cd09-0410-ab3c-d52691b4dbfc

18 files changed:
WebCore/ChangeLog
WebCore/WebCore.exp.in
WebCore/platform/mac/WebCoreSystemInterface.h
WebCore/platform/mac/WebCoreSystemInterface.mm
WebKit/mac/ChangeLog
WebKit/mac/Plugins/Hosted/NetscapePluginHostManager.h
WebKit/mac/Plugins/Hosted/NetscapePluginHostManager.mm
WebKit/mac/Plugins/Hosted/NetscapePluginHostProxy.mm
WebKit/mac/Plugins/Hosted/WebKitPluginClient.defs
WebKit/mac/Plugins/Hosted/WebKitPluginHost.defs
WebKit/mac/WebCoreSupport/WebSystemInterface.mm
WebKit/mac/WebView/WebPreferenceKeysPrivate.h
WebKit/mac/WebView/WebPreferences.mm
WebKit/mac/WebView/WebPreferencesPrivate.h
WebKit2/ChangeLog
WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm
WebKitLibraries/ChangeLog
WebKitLibraries/WebKitSystemInterface.h

index f6cae20..c2e51a3 100644 (file)
@@ -1,3 +1,14 @@
+2010-10-28  Ivan Krstić  <ike@apple.com>
+
+        Reviewed by Mark Rowe.
+
+        Remove unused experimental proxied panel interface.
+        <rdar://problem/7237059>
+
+        * WebCore.exp.in:
+        * platform/mac/WebCoreSystemInterface.h:
+        * platform/mac/WebCoreSystemInterface.mm:
+
 2010-10-27  Andy Estes  <aestes@apple.com>
 
         Reviewed by Adam Barth.
index 13ba92d..39e6b36 100644 (file)
@@ -1169,7 +1169,6 @@ _wkInitializeMaximumHTTPConnectionCountPerHost
 _wkIsLatchingWheelEvent
 _wkMeasureMediaUIPart
 _wkMediaControllerThemeAvailable
-_wkNoteOpenPanelFiles
 _wkPopupMenu
 _wkQTIncludeOnlyModernMediaFileTypes
 _wkQTMovieDataRate
index 64fc54a..758639d 100644 (file)
@@ -48,7 +48,6 @@ typedef struct _NSRect NSRect;
 @class NSFont;
 @class NSImage;
 @class NSMenu;
-@class NSMutableArray;
 @class NSMutableURLRequest;
 @class NSString;
 @class NSTextFieldCell;
@@ -172,10 +171,8 @@ extern BOOL (*wkSupportsMultipartXMixedReplace)(NSMutableURLRequest *);
 extern BOOL (*wkUseSharedMediaUI)();
 
 #if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-extern NSMutableArray *(*wkNoteOpenPanelFiles)(NSArray *);
 extern void* wkGetHyphenationLocationBeforeIndex;
 #else
-extern void* wkNoteOpenPanelFiles;
 extern CFIndex (*wkGetHyphenationLocationBeforeIndex)(CFStringRef string, CFIndex index);
 #endif
 
index 217f04c..1882674 100644 (file)
@@ -114,9 +114,7 @@ BOOL (*wkSupportsMultipartXMixedReplace)(NSMutableURLRequest *);
 #endif
 
 #if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-NSMutableArray *(*wkNoteOpenPanelFiles)(NSArray *);
 void* wkGetHyphenationLocationBeforeIndex;
 #else
-void* wkNoteOpenPanelFiles;
 CFIndex (*wkGetHyphenationLocationBeforeIndex)(CFStringRef string, CFIndex index);
 #endif
index d58df78..ee46d53 100644 (file)
@@ -1,3 +1,25 @@
+2010-10-28  Ivan Krstić  <ike@apple.com>
+
+        Reviewed by Mark Rowe.
+
+        Remove unused experimental proxied panel interface.
+        <rdar://problem/7237059>
+
+        * Plugins/Hosted/NetscapePluginHostManager.h:
+        * Plugins/Hosted/NetscapePluginHostManager.mm:
+        (WebKit::NetscapePluginHostManager::hostForPlugin):
+        (WebKit::NetscapePluginHostManager::spawnPluginHost):
+        (WebKit::NetscapePluginHostManager::instantiatePlugin):
+        * Plugins/Hosted/NetscapePluginHostProxy.mm:
+        * Plugins/Hosted/WebKitPluginClient.defs:
+        * Plugins/Hosted/WebKitPluginHost.defs:
+        * WebCoreSupport/WebSystemInterface.mm:
+        (InitWebCoreSystemInterface):
+        * WebView/WebPreferenceKeysPrivate.h:
+        * WebView/WebPreferences.mm:
+        (+[WebPreferences initialize]):
+        * WebView/WebPreferencesPrivate.h:
+
 2010-10-27  Pratik Solanki  <psolanki@apple.com>
 
         Reviewed by Darin Adler.
index 2645c55..4e59456 100644 (file)
@@ -53,12 +53,12 @@ public:
     void didCreateWindow();
     
 private:
-    NetscapePluginHostProxy* hostForPlugin(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, const WTF::String& bundleIdentifier, bool useProxiedOpenPanel);
+    NetscapePluginHostProxy* hostForPlugin(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, const WTF::String& bundleIdentifier);
 
     NetscapePluginHostManager();
     ~NetscapePluginHostManager();
     
-    bool spawnPluginHost(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, mach_port_t clientPort, mach_port_t& pluginHostPort, ProcessSerialNumber& pluginHostPSN, bool useProxiedOpenPanel);
+    bool spawnPluginHost(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, mach_port_t clientPort, mach_port_t& pluginHostPort, ProcessSerialNumber& pluginHostPSN);
     
     bool initializeVendorPort();
     
index 322e0e8..d8cd081 100644 (file)
 #import "NetscapePluginInstanceProxy.h"
 #import "WebLocalizableStrings.h"
 #import "WebKitSystemInterface.h"
-#import "WebHostedNetscapePluginView.h"
 #import "WebNetscapePluginPackage.h"
-#import "WebPreferencesPrivate.h"
-#import "WebView.h"
 #import <mach/mach_port.h>
 #import <servers/bootstrap.h>
 #import <spawn.h>
@@ -70,7 +67,7 @@ NetscapePluginHostManager::~NetscapePluginHostManager()
 {
 }
 
-NetscapePluginHostProxy* NetscapePluginHostManager::hostForPlugin(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, const String& bundleIdentifier, bool useProxiedOpenPanel)
+NetscapePluginHostProxy* NetscapePluginHostManager::hostForPlugin(const WTF::String& pluginPath, cpu_type_t pluginArchitecture, const String& bundleIdentifier)
 {
     pair<PluginHostMap::iterator, bool> result = m_pluginHosts.add(pluginPath, 0);
     
@@ -86,7 +83,7 @@ NetscapePluginHostProxy* NetscapePluginHostManager::hostForPlugin(const WTF::Str
     
     mach_port_t pluginHostPort;
     ProcessSerialNumber pluginHostPSN;
-    if (!spawnPluginHost(pluginPath, pluginArchitecture, clientPort, pluginHostPort, pluginHostPSN, useProxiedOpenPanel)) {
+    if (!spawnPluginHost(pluginPath, pluginArchitecture, clientPort, pluginHostPort, pluginHostPSN)) {
         mach_port_destroy(mach_task_self(), clientPort);
         m_pluginHosts.remove(result.first);
         return 0;
@@ -103,7 +100,7 @@ NetscapePluginHostProxy* NetscapePluginHostManager::hostForPlugin(const WTF::Str
     return hostProxy;
 }
 
-bool NetscapePluginHostManager::spawnPluginHost(const String& pluginPath, cpu_type_t pluginArchitecture, mach_port_t clientPort, mach_port_t& pluginHostPort, ProcessSerialNumber& pluginHostPSN, bool useProxiedOpenPanel)
+bool NetscapePluginHostManager::spawnPluginHost(const String& pluginPath, cpu_type_t pluginArchitecture, mach_port_t clientPort, mach_port_t& pluginHostPort, ProcessSerialNumber& pluginHostPSN)
 {
     if (m_pluginVendorPort == MACH_PORT_NULL) {
         if (!initializeVendorPort())
@@ -123,7 +120,6 @@ bool NetscapePluginHostManager::spawnPluginHost(const String& pluginPath, cpu_ty
                                       pluginHostAppExecutablePath, @"pluginHostPath",
                                       [NSNumber numberWithInt:pluginArchitecture], @"cpuType",
                                       localization.get(), @"localization",
-                                      [NSNumber numberWithBool:useProxiedOpenPanel], @"useProxiedOpenPanel",
                                       nil];
 
     NSData *data = [NSPropertyListSerialization dataFromPropertyList:launchProperties format:NSPropertyListBinaryFormat_v1_0 errorDescription:0];
@@ -217,8 +213,7 @@ void NetscapePluginHostManager::pluginHostDied(NetscapePluginHostProxy* pluginHo
 
 PassRefPtr<NetscapePluginInstanceProxy> NetscapePluginHostManager::instantiatePlugin(const String& pluginPath, cpu_type_t pluginArchitecture, const String& bundleIdentifier, WebHostedNetscapePluginView *pluginView, NSString *mimeType, NSArray *attributeKeys, NSArray *attributeValues, NSString *userAgent, NSURL *sourceURL, bool fullFrame, bool isPrivateBrowsingEnabled, bool isAcceleratedCompositingEnabled)
 {
-    WebPreferences *preferences = [[pluginView webView] preferences];
-    NetscapePluginHostProxy* hostProxy = hostForPlugin(pluginPath, pluginArchitecture, bundleIdentifier, [preferences usesProxiedOpenPanel]);
+    NetscapePluginHostProxy* hostProxy = hostForPlugin(pluginPath, pluginArchitecture, bundleIdentifier);
     if (!hostProxy)
         return 0;
 
@@ -257,7 +252,7 @@ PassRefPtr<NetscapePluginInstanceProxy> NetscapePluginHostManager::instantiatePl
         pluginHostDied(hostProxy);
 
         // Try to spawn it again.
-        hostProxy = hostForPlugin(pluginPath, pluginArchitecture, bundleIdentifier, [preferences usesProxiedOpenPanel]);
+        hostProxy = hostForPlugin(pluginPath, pluginArchitecture, bundleIdentifier);
         
         // Create a new instance.
         instance = NetscapePluginInstanceProxy::create(hostProxy, pluginView, fullFrame);
index 207f062..067b8bb 100644 (file)
@@ -1120,61 +1120,6 @@ kern_return_t WKPCResolveURL(mach_port_t clientPort, uint32_t pluginID, data_t u
     return KERN_SUCCESS;
 }
 
-#if !defined(BUILDING_ON_SNOW_LEOPARD)
-kern_return_t WKPCRunSyncOpenPanel(mach_port_t clientPort, data_t panelData, mach_msg_type_number_t panelDataLength)
-{
-    DataDeallocator panelDataDeallocator(panelData, panelDataLength);
-
-    NetscapePluginHostProxy* hostProxy = pluginProxyMap().get(clientPort);
-    if (!hostProxy)
-        return KERN_FAILURE;
-
-    NSOpenPanel *sheet = [NSOpenPanel openPanel];
-    NSDictionary *panelState = [NSPropertyListSerialization propertyListFromData:[NSData dataWithBytes:panelData length:panelDataLength]
-                                                                mutabilityOption:NSPropertyListImmutable
-                                                                          format:NULL
-                                                                errorDescription:nil];
-    
-    [sheet setCanChooseFiles:[[panelState objectForKey:@"canChooseFiles"] boolValue]];
-    [sheet setCanChooseDirectories:[[panelState objectForKey:@"canChooseDirectories"] boolValue]];
-    [sheet setResolvesAliases:[[panelState objectForKey:@"resolvesAliases"] boolValue]];
-    [sheet setAllowsMultipleSelection:[[panelState objectForKey:@"allowsMultipleSelection"] boolValue]];
-    [sheet setCanCreateDirectories:[[panelState objectForKey:@"canCreateDirectories"] boolValue]];
-    [sheet setShowsHiddenFiles:[[panelState objectForKey:@"showsHiddenFiles"] boolValue]];
-    [sheet setExtensionHidden:[[panelState objectForKey:@"isExtensionHidden"] boolValue]];
-    [sheet setCanSelectHiddenExtension:[[panelState objectForKey:@"canSelectHiddenExtension"] boolValue]];
-    [sheet setAllowsOtherFileTypes:[[panelState objectForKey:@"allowsOtherFileTypes"] boolValue]];
-    [sheet setTreatsFilePackagesAsDirectories:[[panelState objectForKey:@"treatsFilePackagesAsDirectories"] boolValue]];
-    [sheet setPrompt:[panelState objectForKey:@"prompt"]];
-    [sheet setNameFieldLabel:[panelState objectForKey:@"nameFieldLabel"]];
-    [sheet setMessage:[panelState objectForKey:@"message"]];
-    [sheet setAllowedFileTypes:[panelState objectForKey:@"allowedFileTypes"]];
-    [sheet setRequiredFileType:[panelState objectForKey:@"requiredFileType"]];    
-    [sheet setTitle:[panelState objectForKey:@"title"]];
-    [sheet runModal];
-
-    NetscapePluginHostProxy* newHostProxy = pluginProxyMap().get(clientPort);
-    if (newHostProxy != hostProxy)
-        return KERN_FAILURE;
-
-    NSDictionary *ret = [NSDictionary dictionaryWithObjectsAndKeys:
-                         [sheet filenames], @"filenames",
-                         WKNoteOpenPanelFiles([sheet filenames]), @"extensions",
-                         nil];
-    
-    RetainPtr<NSData*> data = [NSPropertyListSerialization dataFromPropertyList:ret format:NSPropertyListBinaryFormat_v1_0 errorDescription:0];
-    ASSERT(data);
-
-    _WKPHSyncOpenPanelReply(hostProxy->port(), const_cast<char *>(static_cast<const char*>([data.get() bytes])), [data.get() length]);
-    return KERN_SUCCESS;
-}
-#else
-kern_return_t WKPCRunSyncOpenPanel(mach_port_t clientPort, data_t panelData, mach_msg_type_number_t panelDataLength)
-{
-    return KERN_FAILURE;
-}
-#endif // !defined(BUILDING_ON_SNOW_LEOPARD)
-
 kern_return_t WKPCSetException(mach_port_t clientPort, data_t message, mach_msg_type_number_t messageCnt)
 {
     DataDeallocator deallocator(message, messageCnt);
index 4129ca1..15fc5fa 100644 (file)
@@ -231,9 +231,6 @@ simpleroutine PCBooleanAndDataReply(clientPort :mach_port_t;
                                     returnValue :boolean_t;
                                     result :data_t);  
 
-simpleroutine PCRunSyncOpenPanel(clientPort :mach_port_t;
-                                 panelData :data_t);
-
 simpleroutine PCSetFullscreenWindowIsShowing(clientPort :mach_port_t;
                                              isShowing :boolean_t);
 
index 5d9df45..fa808ac 100644 (file)
@@ -240,9 +240,6 @@ simpleroutine PHPluginInstancePrivateBrowsingModeDidChange(pluginHostPort :mach_
                                                            pluginID :uint32_t;
                                                            privateBrowsingEnabled :boolean_t);
 
-simpleroutine PHSyncOpenPanelReply(pluginHostPort :mach_port_t;
-                                   filenames :data_t);
-
 simpleroutine PHPluginInstanceSnapshot(pluginHostPort :mach_port_t;
                                     pluginID :uint32_t;
                                     requestID :uint32_t;
index caea204..df3ea4d 100644 (file)
@@ -114,10 +114,6 @@ void InitWebCoreSystemInterface(void)
     INIT(SupportsMultipartXMixedReplace);
 #endif
 
-#if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-    INIT(NoteOpenPanelFiles);
-#endif
-
 #if defined(BUILDING_ON_TIGER) || defined(BUILDING_ON_LEOPARD) || defined(BUILDING_ON_SNOW_LEOPARD)
     INIT(GetHyphenationLocationBeforeIndex);
 #endif
index cd9ed8f..5c6b530 100644 (file)
@@ -93,7 +93,6 @@
 #define WebKitShowRepaintCounterPreferenceKey @"WebKitShowRepaintCounter"
 #define WebKitWebGLEnabledPreferenceKey @"WebKitWebGLEnabled"
 #define WebKitAccelerated2dCanvasEnabledPreferenceKey @"WebKitAccelerated2dCanvasEnabled"
-#define WebKitUsesProxiedOpenPanelPreferenceKey @"WebKitUsesProxiedOpenPanel"
 #define WebKitPluginAllowedRunTimePreferenceKey @"WebKitPluginAllowedRunTime"
 #define WebKitFrameFlatteningEnabledPreferenceKey @"WebKitFrameFlatteningEnabled"
 #define WebKitSpatialNavigationEnabledPreferenceKey @"WebKitSpatialNavigationEnabled"
index ccfb632..ed06188 100644 (file)
@@ -362,7 +362,6 @@ static WebCacheModel cacheModelForMainBundle(void)
         [NSNumber numberWithBool:NO],   WebKitShowRepaintCounterPreferenceKey,
         [NSNumber numberWithBool:NO],   WebKitWebGLEnabledPreferenceKey,
         [NSNumber numberWithBool:NO],   WebKitAccelerated2dCanvasEnabledPreferenceKey,
-        [NSNumber numberWithBool:NO],   WebKitUsesProxiedOpenPanelPreferenceKey,
         [NSNumber numberWithUnsignedInt:4], WebKitPluginAllowedRunTimePreferenceKey,
         [NSNumber numberWithBool:NO],   WebKitFrameFlatteningEnabledPreferenceKey,
         [NSNumber numberWithBool:NO],   WebKitSpatialNavigationEnabledPreferenceKey,
@@ -1284,16 +1283,6 @@ static NSString *classIBCreatorID = nil;
     [self _setBoolValue:enabled forKey:WebKitAccelerated2dCanvasEnabledPreferenceKey];
 }
 
-- (BOOL)usesProxiedOpenPanel
-{
-    return [self _boolValueForKey:WebKitUsesProxiedOpenPanelPreferenceKey];
-}
-
-- (void)setUsesProxiedOpenPanel:(BOOL)enabled
-{
-    [self _setBoolValue:enabled forKey:WebKitUsesProxiedOpenPanelPreferenceKey];
-}
-
 - (unsigned)pluginAllowedRunTime
 {
     return [self _integerValueForKey:WebKitPluginAllowedRunTimePreferenceKey];
index 47e6d71..2ec08e8 100644 (file)
@@ -193,9 +193,6 @@ extern NSString *WebPreferencesRemovedNotification;
 - (BOOL)paginateDuringLayoutEnabled;
 - (void)setPaginateDuringLayoutEnabled:(BOOL)flag;
 
-- (BOOL)usesProxiedOpenPanel;
-- (void)setUsesProxiedOpenPanel:(BOOL)enabled;
-
 - (BOOL)memoryInfoEnabled;
 - (void)setMemoryInfoEnabled:(BOOL)enabled;
 
index 58da044..a8dde35 100644 (file)
@@ -1,3 +1,13 @@
+2010-10-28  Ivan Krstić  <ike@apple.com>
+
+        Reviewed by Mark Rowe.
+
+        Remove unused experimental proxied panel interface.
+        <rdar://problem/7237059>
+
+        * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
+        (InitWebCoreSystemInterface):
+
 2010-10-27  Mark Rowe  <mrowe@apple.com>
 
         Build fix.
index 6c89bbd..9450745 100644 (file)
@@ -90,10 +90,6 @@ void InitWebCoreSystemInterface(void)
         INIT(SignalCFReadStreamError);
         INIT(SignalCFReadStreamHasBytes);
 
-    #if !defined(BUILDING_ON_SNOW_LEOPARD)
-        INIT(NoteOpenPanelFiles);
-    #endif
-
     #if defined(BUILDING_ON_SNOW_LEOPARD)
         INIT(GetHyphenationLocationBeforeIndex);
     #endif
index 96a8be2..0f9bce1 100644 (file)
@@ -1,3 +1,12 @@
+2010-10-28  Ivan Krstić  <ike@apple.com>
+
+        Reviewed by Mark Rowe.
+
+        Remove unused experimental proxied panel interface.
+        <rdar://problem/7237059>
+
+        * WebKitSystemInterface.h:
+
 2010-10-27  Anders Carlsson  <andersca@apple.com>
 
         Reviewed by Sam Weinig.
index 3e94071..01f408b 100644 (file)
@@ -324,7 +324,6 @@ void WKWindowSetScaledFrame(NSWindow *window, NSRect scaleFrame, NSRect nonScale
 #endif
 
 #if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD)
-NSMutableArray *WKNoteOpenPanelFiles(NSArray *paths);
 void WKSyncSurfaceToView(NSView *view);
 #endif