From: Alan Third Date: Tue, 14 Jan 2020 21:36:14 +0000 (+0000) Subject: Remove EmacsOpenPanel and EmacsSavePanel (bug#38031) X-Git-Tag: emacs-27.0.90~102 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0bed550e21;p=emacs.git Remove EmacsOpenPanel and EmacsSavePanel (bug#38031) --- diff --git a/src/nsfns.m b/src/nsfns.m index 93d5a1e9488..0f879fe390c 100644 --- a/src/nsfns.m +++ b/src/nsfns.m @@ -1622,7 +1622,7 @@ Optional arg DIR_ONLY_P, if non-nil, means choose only directories. */) dirS = [dirS stringByExpandingTildeInPath]; panel = isSave ? - (id)[EmacsSavePanel savePanel] : (id)[EmacsOpenPanel openPanel]; + (id)[NSSavePanel savePanel] : (id)[NSOpenPanel openPanel]; [panel setTitle: promptS]; @@ -3077,29 +3077,6 @@ handlePanelKeys (NSSavePanel *panel, NSEvent *theEvent) return ret; } -@implementation EmacsSavePanel -- (BOOL)performKeyEquivalent:(NSEvent *)theEvent -{ - BOOL ret = handlePanelKeys (self, theEvent); - if (! ret) - ret = [super performKeyEquivalent:theEvent]; - return ret; -} -@end - - -@implementation EmacsOpenPanel -- (BOOL)performKeyEquivalent:(NSEvent *)theEvent -{ - // NSOpenPanel inherits NSSavePanel, so passing self is OK. - BOOL ret = handlePanelKeys (self, theEvent); - if (! ret) - ret = [super performKeyEquivalent:theEvent]; - return ret; -} -@end - - @implementation EmacsFileDelegate /* -------------------------------------------------------------------------- Delegate methods for Open/Save panels diff --git a/src/nsterm.h b/src/nsterm.h index fb9ac1b462c..f68c3246a70 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -595,22 +595,6 @@ typedef id instancetype; @end -/* ========================================================================== - - File open/save panels - This and next override methods to handle keyboard input in panels. - - ========================================================================== */ - -@interface EmacsSavePanel : NSSavePanel -{ -} -@end -@interface EmacsOpenPanel : NSOpenPanel -{ -} -@end - @interface EmacsFileDelegate : NSObject { }