KMSavePanelAccessoryController.m 843 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. //
  2. // KMSavePanelAccessoryController.m
  3. // PDF Reader
  4. //
  5. // Created by 蒋志鹏 on 2018/9/26.
  6. // Copyright © 2018年 Kdan Mobile. All rights reserved.
  7. //
  8. #import "KMSavePanelAccessoryController.h"
  9. @interface KMSavePanelAccessoryController ()
  10. @property (nonatomic, assign) BOOL needOpen;
  11. @end
  12. @implementation KMSavePanelAccessoryController
  13. - (instancetype)init
  14. {
  15. self = [super initWithNibName:@"KMSavePanelAccessoryController" bundle:nil];
  16. if (self) {
  17. }
  18. return self;
  19. }
  20. - (void)awakeFromNib
  21. {
  22. [super awakeFromNib];
  23. self.openAutomaticButton.title = NSLocalizedString(@"Open the document after saving", nil);
  24. self.openAutomaticButton.state = NSControlStateValueOff;
  25. }
  26. - (IBAction)buttonClicked_OpenAutomatic:(NSButton *)sender
  27. {
  28. _needOpen = sender.state == NSControlStateValueOn;
  29. }
  30. @end