Merge pull request #58 from marhali/fix/npe-key-annotator
Fix/npe key annotator
This commit is contained in:
commit
ee9a834253
@ -3,6 +3,9 @@
|
||||
# easy-i18n Changelog
|
||||
|
||||
## [Unreleased]
|
||||
### Fixed
|
||||
- Exception on key annotation if path-prefix is undefined
|
||||
|
||||
## [1.5.0]
|
||||
### Added
|
||||
- Support for YAML locale files. Thanks to @sunarya-thito
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
pluginGroup = de.marhali.easyi18n
|
||||
pluginName = easy-i18n
|
||||
pluginVersion = 1.5.0
|
||||
pluginVersion = 1.5.1
|
||||
|
||||
# See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
|
||||
# for insight into build numbers and IntelliJ Platform versions.
|
||||
|
@ -11,6 +11,7 @@ public class SettingsState {
|
||||
|
||||
public static final String DEFAULT_PREVIEW_LOCALE = "en";
|
||||
public static final String DEFAULT_FILE_PATTERN = ".*";
|
||||
public static final String DEFAULT_PATH_PREFIX = "";
|
||||
public static final boolean DEFAULT_CODE_ASSISTANCE = true;
|
||||
|
||||
private String localesPath;
|
||||
@ -45,6 +46,14 @@ public class SettingsState {
|
||||
this.previewLocale = previewLocale;
|
||||
}
|
||||
|
||||
public @NotNull String getPathPrefix() {
|
||||
return pathPrefix != null ? pathPrefix : DEFAULT_PATH_PREFIX;
|
||||
}
|
||||
|
||||
public void setPathPrefix(String pathPrefix) {
|
||||
this.pathPrefix = pathPrefix;
|
||||
}
|
||||
|
||||
public boolean isCodeAssistance() {
|
||||
return codeAssistance == null ? DEFAULT_CODE_ASSISTANCE : codeAssistance;
|
||||
}
|
||||
@ -52,12 +61,4 @@ public class SettingsState {
|
||||
public void setCodeAssistance(boolean codeAssistance) {
|
||||
this.codeAssistance = codeAssistance;
|
||||
}
|
||||
|
||||
public void setPathPrefix(String pathPrefix) {
|
||||
this.pathPrefix = pathPrefix;
|
||||
}
|
||||
|
||||
public String getPathPrefix() {
|
||||
return pathPrefix;
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user