2
0

VMDisplayMetalViewController.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. //
  2. // Copyright © 2019 osy. All rights reserved.
  3. //
  4. // Licensed under the Apache License, Version 2.0 (the "License");
  5. // you may not use this file except in compliance with the License.
  6. // You may obtain a copy of the License at
  7. //
  8. // http://www.apache.org/licenses/LICENSE-2.0
  9. //
  10. // Unless required by applicable law or agreed to in writing, software
  11. // distributed under the License is distributed on an "AS IS" BASIS,
  12. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. // See the License for the specific language governing permissions and
  14. // limitations under the License.
  15. //
  16. #import <UIKit/UIKit.h>
  17. #import "VMDisplayViewController.h"
  18. #if !defined(WITH_USB)
  19. @import CocoaSpiceNoUsb;
  20. #else
  21. @import CocoaSpice;
  22. #endif
  23. @class VMKeyboardView;
  24. @class VMKeyboardButton;
  25. NS_ASSUME_NONNULL_BEGIN
  26. @interface VMDisplayMetalViewController : VMDisplayViewController
  27. @property (strong, nonatomic) IBOutlet UIInputView *inputAccessoryView;
  28. @property (strong, nonatomic) IBOutletCollection(VMKeyboardButton) NSArray *customKeyModifierButtons;
  29. @property (nonatomic) IBOutlet MTKView *mtkView;
  30. @property (nonatomic) IBOutlet VMKeyboardView *keyboardView;
  31. @property (nonatomic, nullable) CSInput *vmInput;
  32. @property (nonatomic) CSDisplay *vmDisplay;
  33. @property (nonatomic, readonly) BOOL serverModeCursor;
  34. @property (nonatomic, strong) NSMutableArray<UIKeyCommand *> *mutableKeyCommands;
  35. @property (nonatomic) BOOL isDynamicResolutionSupported;
  36. - (instancetype)initWithCoder:(NSCoder *)coder NS_UNAVAILABLE;
  37. - (instancetype)initWithNibName:(nullable NSString *)nibNameOrNil bundle:(nullable NSBundle *)nibBundleOrNil NS_UNAVAILABLE;
  38. - (instancetype)initWithDisplay:(CSDisplay *)display input:(nullable CSInput *)input NS_DESIGNATED_INITIALIZER;
  39. - (void)sendExtendedKey:(CSInputKey)type code:(int)code;
  40. - (void)setDisplayScaling:(CGFloat)scaling origin:(CGPoint)origin;
  41. @end
  42. NS_ASSUME_NONNULL_END