Commit 42ed3564 authored by hyatt's avatar hyatt
Browse files

Back out fix for 13972. Quicktime will no longer clip correctly. :(

        Too many regressions in Mail caused by inserting an extra view into the
        hierarchy.  Can revisit later.

        Reviewed by olliej

        * Plugins/WebPluginController.mm:
        (-[WebPluginController destroyPlugin:]):
        (-[WebPluginController destroyAllPlugins]):
        * WebCoreSupport/WebFrameBridge.mm:
        (-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
        * WebView/WebHTMLView.mm:
        (-[WebHTMLView addSubview:]):
        (-[WebHTMLView willRemoveSubview:]):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@23559 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 2316be23
2007-06-16 David Hyatt <hyatt@apple.com>
Back out fix for 13972. Quicktime will no longer clip correctly. :(
Too many regressions in Mail caused by inserting an extra view into the
hierarchy. Can revisit later.
Reviewed by olliej
* Plugins/WebPluginController.mm:
(-[WebPluginController destroyPlugin:]):
(-[WebPluginController destroyAllPlugins]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
* WebView/WebHTMLView.mm:
(-[WebHTMLView addSubview:]):
(-[WebHTMLView willRemoveSubview:]):
2007-06-15 Sam Weinig <sam@webkit.org>
 
Reviewed by Darin.
......
......@@ -30,7 +30,6 @@
#import <WebKit/WebPluginController.h>
#import <Foundation/NSURLRequest.h>
#import <WebCore/Frame.h>
#import <WebCore/FrameLoader.h>
#import <WebCore/ResourceRequest.h>
#import <WebCore/PlatformString.h>
......@@ -54,8 +53,6 @@
#import <WebKit/WebUIDelegate.h>
#import <WebKit/WebViewInternal.h>
using namespace WebCore;
@interface NSView (PluginSecrets)
- (void)setContainingWindow:(NSWindow *)w;
@end
......@@ -232,9 +229,6 @@ static NSMutableSet *pluginViews = nil;
[view pluginDestroy];
}
if (Frame* frame = core([self webFrame]))
frame->cleanupScriptObjectsForPlugin(view);
[pluginViews removeObject:view];
[_views removeObject:view];
}
......@@ -273,7 +267,6 @@ static void cancelOutstandingCheck(const void *item, void *context)
int i, count = [_views count];
for (i = 0; i < count; i++) {
id aView = [_views objectAtIndex:i];
if ([aView respondsToSelector:@selector(webPlugInDestroy)]) {
KJS::JSLock::DropAllLocks dropAllLocks;
[aView webPlugInDestroy];
......@@ -281,16 +274,9 @@ static void cancelOutstandingCheck(const void *item, void *context)
KJS::JSLock::DropAllLocks dropAllLocks;
[aView pluginDestroy];
}
if (Frame* frame = core([self webFrame]))
frame->cleanupScriptObjectsForPlugin(aView);
[pluginViews removeObject:aView];
// Remove the containing view.
[[aView superview] removeFromSuperviewWithoutNeedingDisplay];
}
[_views makeObjectsPerformSelector:@selector(removeFromSuperviewWithoutNeedingDisplay)];
[_views release];
_views = nil;
......
......@@ -419,15 +419,8 @@ NSString *WebPluginContainerKey = @"WebPluginContainer";
view = [WebPluginController plugInViewWithArguments:arguments fromPluginPackage:pluginPackage];
[view setAutoresizingMask:(NSViewWidthSizable | NSViewHeightSizable)];
[attributes release];
WebKitPluginContainerView* containerView = [[[WebKitPluginContainerView alloc] initWithFrame:NSZeroRect DOMElement:element] autorelease];
[view setFrame:NSZeroRect];
[containerView setAutoresizesSubviews:YES];
[containerView addSubview:view];
return containerView;
return view;
}
- (NSString *)valueForKey:(NSString *)key keys:(NSArray *)keys values:(NSArray *)values
......
......@@ -2439,14 +2439,15 @@ static NSURL* uniqueURLWithRelativePart(NSString *relativePart)
{
[super addSubview:view];
if ([view isKindOfClass:[WebKitPluginContainerView class]])
[[self _pluginController] addPlugin:[[view subviews] objectAtIndex:0]];
if ([WebPluginController isPlugInView:view])
[[self _pluginController] addPlugin:view];
}
- (void)willRemoveSubview:(NSView *)subview
{
if ([subview isKindOfClass:[WebKitPluginContainerView class]])
[[self _pluginController] destroyPlugin:[[subview subviews] objectAtIndex:0]];
if ([WebPluginController isPlugInView:subview])
[[self _pluginController] destroyPlugin:subview];
[super willRemoveSubview:subview];
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment