-
Notifications
You must be signed in to change notification settings - Fork 191
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
Add a setting to control page size #686
Add a setting to control page size #686
Conversation
extensions/ql-vscode/CHANGELOG.md
Outdated
@@ -9,6 +9,7 @@ | |||
- Add more structured output for tests. [#626](https://github.com/github/vscode-codeql/pull/626) | |||
- Whenever the extension restarts, orphaned databases will be cleaned up. These are databases whose files are located inside of the extension's storage area, but are not imported into the workspace. | |||
- After renaming a database, the database list is re-sorted. [#685](https://github.com/github/vscode-codeql/pull/685) | |||
- Add a setting to configure number of results displayed in a single results view page. [#686](https://github.com/github/vscode-codeql/pull/686) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Add a setting to configure number of results displayed in a single results view page. [#686](https://github.com/github/vscode-codeql/pull/686) | |
- Add a `codeQl.runningQueries.pageSize` setting to configure the number of results displayed in a single results view page. [#686](https://github.com/github/vscode-codeql/pull/686). Increase the default page size from 100 to 200. |
(edit if you rename the setting)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
extensions/ql-vscode/package.json
Outdated
@@ -157,6 +157,11 @@ | |||
"default": 20, | |||
"description": "Max number of simultaneous queries to run using the 'CodeQL: Run Queries' command." | |||
}, | |||
"codeQL.runningQueries.pageSize": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think of runningQueries
as options for executing query. Would queryHistory
be a better category, or perhaps a new one for the results view (like we do for subcommands)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe makes more sense to create a new category, codeQL.results
or codeQL.display
or codeQL.resultsDisplay
. (I'm leaning towards the latter).
@@ -488,13 +489,14 @@ export class InterfaceManager extends DisposableObject { | |||
schema.name, | |||
{ | |||
offset: schema.pagination?.offsets[pageNumber], | |||
pageSize: RAW_RESULTS_PAGE_SIZE | |||
pageSize: PAGE_SIZE.getValue() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: you can fetch the page size setting once and save it to a variable for the below uses.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Also, set a max and min value on the input control of the page. This prevents going to a negative page, or a page after the last one.
196a651
to
f1e714e
Compare
Also, set a max and min value on the input control of the page. This
prevents going to a negative page, or a page after the last one.
Fixes #525
Checklist
@github/docs-content-dsp
has been cc'd in all issues for UI or other user-facing changes made by this pull request.