1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 11:07:45 +00:00

MacPDF: Start moving window-related things into MacPDFWindowController

- MacPDFWindowController is now the xib file's owner
- _pdfView moves over
- MacPDFWindowController is now the MacPDFViewDelegate and responsible
  for updating the window's title
- Due to MacPDFWindowController now being the xib file's owner,
  windowControllerDidLoadNib: is no longer called automatically,
  so call a custom windowIsReady method manually instead

No behavior change.
This commit is contained in:
Nico Weber 2023-10-03 08:24:45 -04:00 committed by Andreas Kling
parent 67f6baead0
commit dcf40892b8
5 changed files with 76 additions and 47 deletions

View file

@ -8,16 +8,14 @@
#include "CocoaWrapper.h"
#import "MacPDFView.h"
#import "MacPDFWindowController.h"
NS_ASSUME_NONNULL_BEGIN
@interface MacPDFDocument : NSDocument <MacPDFViewDelegate>
{
IBOutlet MacPDFView* _pdfView;
}
@interface MacPDFDocument : NSDocument
- (IBAction)showGoToPageDialog:(id)sender;
- (PDF::Document*)pdf;
- (void)windowIsReady;
@end