Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: update roadmap for split and new #3184

Merged
merged 2 commits into from
Nov 1, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -524,9 +524,9 @@ Since the list is too long, now we just put those already supported options here
| ------------------------- | ----------------- | ----------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| :white_check_mark: :star: | :e[dit] {file} | Edit {file}. | We will open file in a new Tab of current Grouped Editor instead of opening in current tab. |
| :white_check_mark: :star: | <ctrl-w> hl | Switching between windows. | As we don't have the concept of Window in VS Code, we are mapping these commands to switching between Grouped Editors. |
| :x: | :sp {file} | Split current window in two. | VS Code doesn't support split Window horizontally. |
| :white_check_mark: | :sp {file} | Split current window in two. | VS Code doesn't support split Window horizontally. |
| :white_check_mark: :star: | :vsp {file} | Split vertically current window in two. | VS Code only supports three vertical window at most and that's the limitation of this command. |
| :x: | :new | Create a new window horizontally and start editing an empty file in it. | VS Code doesn't support split Window horizontally. |
| :white_check_mark: | :new | Create a new window horizontally and start editing an empty file in it. | VS Code doesn't support split Window horizontally. |
| :white_check_mark: :star: | :vne[w] | Create a new window vertically and start editing an empty file in it. | VS Code only supports three vertical window at most and that's the limitation of this command. |

## Tabs
Expand Down
20 changes: 5 additions & 15 deletions src/configuration/configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -287,24 +287,14 @@ class Configuration implements IConfiguration {
@overlapSetting({
settingName: 'lineNumbers',
defaultValue: true,
map: new Map([
['on', true],
['off', false],
['relative', false],
['interval', false],
]),
map: new Map([['on', true], ['off', false], ['relative', false], ['interval', false]]),
})
number: boolean;

@overlapSetting({
settingName: 'lineNumbers',
defaultValue: false,
map: new Map([
['on', false],
['off', false],
['relative', true],
['interval', false],
]),
map: new Map([['on', false], ['off', false], ['relative', true], ['interval', false]]),
})
relativenumber: boolean;

Expand Down Expand Up @@ -374,9 +364,9 @@ function overlapSetting(args: {
defaultValue: OptionValue;
map?: Map<string | number | boolean, string | number | boolean>;
}) {
return function (target: any, propertyKey: string) {
return function(target: any, propertyKey: string) {
Object.defineProperty(target, propertyKey, {
get: function () {
get: function() {
if (this['_' + propertyKey] !== undefined) {
return this['_' + propertyKey];
}
Expand All @@ -388,7 +378,7 @@ function overlapSetting(args: {

return val;
},
set: function (value) {
set: function(value) {
this['_' + propertyKey] = value;

if (value === undefined || Globals.isTesting) {
Expand Down
4 changes: 3 additions & 1 deletion src/configuration/remapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,9 @@ export class Remapper implements IRemapper {
await vimState.historyTracker.undoAndRemoveChanges(
Math.max(0, numCharsToRemove * vimState.allCursors.length)
);
vimState.allCursors = vimState.allCursors.map(x => x.withNewStop(x.stop.getLeft(numCharsToRemove)));
vimState.allCursors = vimState.allCursors.map(x =>
x.withNewStop(x.stop.getLeft(numCharsToRemove))
);
}

// We need to remove the keys that were remapped into different keys
Expand Down
4 changes: 1 addition & 3 deletions src/util/historyFile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,7 @@ export class HistoryFile {
mkdirp.sync(this._historyDir, 0o775);
}
} catch (err) {
logger.error(
`Failed to create directory. path=${this._historyDir}. err=${err}.`
);
logger.error(`Failed to create directory. path=${this._historyDir}. err=${err}.`);
reject(err);
}

Expand Down