Skip to content

Commit

Permalink
changed inlay hints defaults to all false
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexHaxe committed Oct 22, 2024
1 parent 1ec7c17 commit 1834428
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions src/haxeLanguageServer/Configuration.hx
Original file line number Diff line number Diff line change
Expand Up @@ -203,10 +203,10 @@ class Configuration {
maxCompletionItems: 1000,
renameSourceFolders: ["src", "source", "Source", "test", "tests"],
inlayHints: {
variableTypes: true,
parameterNames: true,
variableTypes: false,
parameterNames: false,
parameterTypes: false,
functionReturnTypes: true,
functionReturnTypes: false,
conditionals: false
},
serverRecording: {
Expand Down
14 changes: 7 additions & 7 deletions src/haxeLanguageServer/features/haxe/InlayHintFeature.hx
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ class InlayHintFeature {
final cache:InlayHintCache;
final hoverRequests:Array<HoverRequestContext<Any>> = [];

var inlayHintsVariableTypes:Bool = true;
var inlayHintsParameterNames:Bool = true;
var inlayHintsVariableTypes:Bool = false;
var inlayHintsParameterNames:Bool = false;
var inlayHintsParameterTypes:Bool = false;
var inlayHintsFunctionReturnTypes:Bool = true;
var inlayHintsFunctionReturnTypes:Bool = false;
var inlayHintsConditionls:Bool = false;

public function new(context:Context) {
Expand Down Expand Up @@ -67,11 +67,11 @@ class InlayHintFeature {
#end
removeCancelledRequests();

inlayHintsVariableTypes = context.config.user?.inlayHints?.variableTypes ?? true;
inlayHintsParameterNames = context.config.user?.inlayHints?.parameterNames ?? true;
inlayHintsVariableTypes = context.config.user?.inlayHints?.variableTypes ?? false;
inlayHintsParameterNames = context.config.user?.inlayHints?.parameterNames ?? false;
inlayHintsParameterTypes = context.config.user?.inlayHints?.parameterTypes ?? false;
inlayHintsFunctionReturnTypes = context.config.user?.inlayHints?.functionReturnTypes ?? true;
inlayHintsConditionls = context.config.user?.inlayHints?.conditionals ?? true;
inlayHintsFunctionReturnTypes = context.config.user?.inlayHints?.functionReturnTypes ?? false;
inlayHintsConditionls = context.config.user?.inlayHints?.conditionals ?? false;

if (!inlayHintsVariableTypes && !inlayHintsParameterNames && !inlayHintsParameterTypes && !inlayHintsFunctionReturnTypes && !inlayHintsConditionls) {
resolve([]);
Expand Down

0 comments on commit 1834428

Please sign in to comment.