blob: 033a19669612745de4b46875f7753fb480cf3a71 [file] [log] [blame]
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef SHELL_PLATFORM_IOS_FRAMEWORK_SOURCE_FLUTTERTEXTINPUTDELEGATE_H_
#define SHELL_PLATFORM_IOS_FRAMEWORK_SOURCE_FLUTTERTEXTINPUTDELEGATE_H_
#import <Foundation/Foundation.h>
typedef NS_ENUM(NSInteger, FlutterTextInputAction) {
FlutterTextInputActionUnspecified,
FlutterTextInputActionDone,
FlutterTextInputActionGo,
FlutterTextInputActionSend,
FlutterTextInputActionSearch,
FlutterTextInputActionNext,
FlutterTextInputActionContinue,
FlutterTextInputActionJoin,
FlutterTextInputActionRoute,
FlutterTextInputActionEmergencyCall,
FlutterTextInputActionNewline,
};
typedef NS_ENUM(NSInteger, FlutterFloatingCursorDragState) {
FlutterFloatingCursorDragStateStart,
FlutterFloatingCursorDragStateUpdate,
FlutterFloatingCursorDragStateEnd,
};
@protocol FlutterTextInputDelegate <NSObject>
- (void)updateEditingClient:(int)client withState:(NSDictionary*)state;
- (void)updateEditingClient:(int)client withState:(NSDictionary*)state withTag:(NSString*)tag;
- (void)performAction:(FlutterTextInputAction)action withClient:(int)client;
- (void)updateFloatingCursor:(FlutterFloatingCursorDragState)state
withClient:(int)client
withPosition:(NSDictionary*)point;
- (void)showAutocorrectionPromptRectForStart:(NSUInteger)start
end:(NSUInteger)end
withClient:(int)client;
@end
#endif // SHELL_PLATFORM_IOS_FRAMEWORK_SOURCE_FLUTTERTEXTINPUTDELEGATE_H_