Changeset 202629 in webkit


Ignore:
Timestamp:
Jun 29, 2016 10:42:01 AM (8 years ago)
Author:
commit-queue@webkit.org
Message:

Replace MPAudioVideoRoutingActionSheet with MPAVRoutingSheet.
https://bugs.webkit.org/show_bug.cgi?id=159161
<rdar://problem/26017691>

Patch by Jeremy Jones <jeremyj@apple.com> on 2016-06-29
Reviewed by Sam Weinig.

Source/WebCore:

Replace MPAudioVideoRoutingActionSheet SPI with MPAVRoutingSheet SPI.

  • platform/spi/ios/MediaPlayerSPI.h:

Source/WebKit2:

MPAudioVideoRoutingActionSheet is being replaced by MPAVRoutingSheet,
with only minor changes to the interface.

  • UIProcess/ios/forms/WKAirPlayRoutePicker.mm:

(-[WKAirPlayRoutePicker dealloc]):
(-[WKAirPlayRoutePicker showAirPlayPickerIPhone:]):

Location:
trunk/Source
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r202628 r202629  
     12016-06-29  Jeremy Jones  <jeremyj@apple.com>
     2
     3        Replace MPAudioVideoRoutingActionSheet with MPAVRoutingSheet.
     4        https://bugs.webkit.org/show_bug.cgi?id=159161
     5        <rdar://problem/26017691>
     6
     7        Reviewed by Sam Weinig.
     8
     9        Replace MPAudioVideoRoutingActionSheet SPI with MPAVRoutingSheet SPI.
     10
     11        * platform/spi/ios/MediaPlayerSPI.h:
     12
    1132016-06-29  Alejandro G. Castro  <alex@igalia.com>
    214
  • trunk/Source/WebCore/platform/spi/ios/MediaPlayerSPI.h

    r190336 r202629  
    3434
    3535#import <MediaPlayer/MPAVRoutingController.h>
    36 #import <MediaPlayer/MPAudioVideoRoutingActionSheet.h>
     36#import <MediaPlayer/MPAVRoutingSheet.h>
    3737#import <MediaPlayer/MPAudioVideoRoutingPopoverController.h>
    3838
     
    7373#pragma clang diagnostic push
    7474#pragma clang diagnostic ignored "-Wdeprecated-declarations"
    75 @interface MPAudioVideoRoutingActionSheet : UIActionSheet
     75@interface MPAVRoutingSheet : UIView
    7676@end
    7777#pragma clang diagnostic pop
    7878
    79 @interface MPAudioVideoRoutingActionSheet ()
    80 - (id)initWithType:(MPAVItemType)avItemType;
    81 - (void)showWithValidInterfaceOrientationMaskBlock:(UIInterfaceOrientationMask (^)(void))block completionHandler:(void (^)())completionHandler;
     79@interface MPAVRoutingSheet ()
     80@property (nonatomic, assign, setter=setAVItemType:) MPAVItemType avItemType;
     81
     82@property (nonatomic, assign) BOOL mirroringOnly;
     83
     84- (id)initWithAVItemType:(MPAVItemType)avItemType;
     85
     86- (void)showInView:(UIView *)view withCompletionHandler:(void (^)(void))completionHandler;
     87
     88- (void)dismiss;
    8289@end
    8390
  • trunk/Source/WebKit2/ChangeLog

    r202621 r202629  
     12016-06-29  Jeremy Jones  <jeremyj@apple.com>
     2
     3        Replace MPAudioVideoRoutingActionSheet with MPAVRoutingSheet.
     4        https://bugs.webkit.org/show_bug.cgi?id=159161
     5        <rdar://problem/26017691>
     6
     7        Reviewed by Sam Weinig.
     8
     9        MPAudioVideoRoutingActionSheet is being replaced by MPAVRoutingSheet,
     10        with only minor changes to the interface.
     11
     12        * UIProcess/ios/forms/WKAirPlayRoutePicker.mm:
     13        (-[WKAirPlayRoutePicker dealloc]):
     14        (-[WKAirPlayRoutePicker showAirPlayPickerIPhone:]):
     15
    1162016-06-29  Carlos Garcia Campos  <cgarcia@igalia.com>
    217
  • trunk/Source/WebKit2/UIProcess/ios/forms/WKAirPlayRoutePicker.mm

    r196260 r202629  
    4343SOFT_LINK_CLASS(MediaPlayer, MPAVRoutingController)
    4444SOFT_LINK_CLASS(MediaPlayer, MPAudioVideoRoutingPopoverController)
    45 SOFT_LINK_CLASS(MediaPlayer, MPAudioVideoRoutingActionSheet)
     45SOFT_LINK_CLASS(MediaPlayer, MPAVRoutingSheet)
    4646
    4747using namespace WebKit;
     
    5050    RetainPtr<MPAVRoutingController> _routingController;
    5151    RetainPtr<MPAudioVideoRoutingPopoverController> _popoverController;  // iPad
    52     RetainPtr<MPAudioVideoRoutingActionSheet> _actionSheet;              // iPhone
     52    RetainPtr<MPAVRoutingSheet> _actionSheet; // iPhone
    5353    WKContentView* _view; // Weak reference.
    5454}
     
    6666{
    6767    // The ActionSheet's completion handler will release and clear the ActionSheet.
    68     [_actionSheet dismissWithClickedButtonIndex:[_actionSheet cancelButtonIndex] animated:YES];
     68    [_actionSheet dismiss];
    6969    [self _dismissAirPlayRoutePickerIPad];
    7070
     
    135135        return;
    136136
    137     _actionSheet = adoptNS([allocMPAudioVideoRoutingActionSheetInstance() initWithType:itemType]);
     137    _actionSheet = adoptNS([allocMPAVRoutingSheetInstance() initWithAVItemType:itemType]);
    138138
    139     [_actionSheet
    140         showWithValidInterfaceOrientationMaskBlock:^UIInterfaceOrientationMask {
    141             return UIInterfaceOrientationMaskPortrait;
    142         }
    143         completionHandler:^{
    144             [_routingController setDiscoveryMode:MPRouteDiscoveryModeDisabled];
    145             _routingController = nil;
    146             _actionSheet = nil;
    147         }
    148      ];
     139    [_actionSheet showInView:_view withCompletionHandler:^{
     140        [_routingController setDiscoveryMode:MPRouteDiscoveryModeDisabled];
     141        _routingController = nil;
     142        _actionSheet = nil;
     143    }];
    149144}
    150145
Note: See TracChangeset for help on using the changeset viewer.