浏览代码

fix shortcuts

/siyaoH-1.17-PlatformMessage
guanghuispark 4 年前
当前提交
a4398858
共有 3 个文件被更改,包括 12 次插入11 次删除
  1. 4
      com.unity.uiwidgets/Runtime/scheduler2/binding.cs
  2. 10
      com.unity.uiwidgets/Runtime/widgets/actions.cs
  3. 9
      com.unity.uiwidgets/Runtime/widgets/shortcuts.cs

4
com.unity.uiwidgets/Runtime/scheduler2/binding.cs


context: "during a task callback",
informationCollector: callbackStack == null
? (InformationCollector) null
: sb => {
: (StringBuilder sb) => {
sb.AppendLine("\nThis exception was thrown in the context of a scheduler callback. " +
"When the scheduler callback was _registered_ (as opposed to when the " +
"exception was thrown), this was the stack: " + callbackStack);

context: "during a scheduler callback",
informationCollector: callbackStack == null
? (InformationCollector) null
: information => {
: (StringBuilder information) => {
information.AppendLine(
"\nThis exception was thrown in the context of a scheduler callback. " +
"When the scheduler callback was _registered_ (as opposed to when the " +

10
com.unity.uiwidgets/Runtime/widgets/actions.cs


bool enabled = true,
FocusNode focusNode = null,
bool autofocus = false,
//Dictionary<LogicalKeySet, Intent> shortcuts = null,
Dictionary<LogicalKeySet, Intent> shortcuts = null,
Dictionary<LocalKey, ActionFactory> actions = null,
ValueChanged<bool> onShowFocusHighlight = null,
ValueChanged<bool> onShowHoverHighlight = null,

this.enabled = enabled;
this.focusNode = focusNode;
this.autofocus = autofocus;
//this.shortcuts = shortcuts;
this.shortcuts = shortcuts;
this.actions = actions;
this.onShowFocusHighlight = onShowFocusHighlight;
this.onShowHoverHighlight = onShowHoverHighlight;

public readonly Dictionary<LocalKey, ActionFactory> actions;
//public readonly Dictionary<LogicalKeySet, Intent> shortcuts;
public readonly Dictionary<LogicalKeySet, Intent> shortcuts;
public readonly ValueChanged<bool> onShowFocusHighlight;

child = new Actions(actions: widget.actions, child: child);
}
/*if (widget.enabled && widget.shortcuts != null && widget.shortcuts.isNotEmpty()) {
if (widget.enabled && widget.shortcuts != null && widget.shortcuts.isNotEmpty()) {
}*/
}
return child;
}
}

9
com.unity.uiwidgets/Runtime/widgets/shortcuts.cs


}
return string.Join(" + ", result.ToArray());
}
public override void debugFillProperties(DiagnosticPropertiesBuilder properties) {
base.debugFillProperties(properties);

}
}
public class ShortcutManager : ChangeNotifier {
public class ShortcutManager : DiagnosticableMixinChangeNotifier {
public ShortcutManager(
Dictionary<LogicalKeySet, Intent> shortcuts = null,

return false;
}
public void debugFillProperties(DiagnosticPropertiesBuilder properties) {
public override void debugFillProperties(DiagnosticPropertiesBuilder properties) {
base.debugFillProperties(properties: properties);
properties.add(new FlagProperty("modal", value: modal, ifTrue: "modal", defaultValue: false));
properties.add(new FlagProperty("modal", value: modal, ifTrue: "modal", defaultValue: false));
}
}

正在加载...
取消
保存