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

fix: correct docs for flyout metrics #6751

Merged
merged 1 commit into from
Jan 10, 2023
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
2 changes: 1 addition & 1 deletion blocks/procedures.js
Original file line number Diff line number Diff line change
Expand Up @@ -975,7 +975,7 @@ const procedureCallerGetDefMixin = function() {
'fields': {'NAME': newName},
};
return serialization.blocks.append(blockDef, this.getTargetWorkspace_())
.getProcedureModel();
.getProcedureModel();
},

/**
Expand Down
14 changes: 8 additions & 6 deletions core/interfaces/i_metrics_manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,14 @@ export interface IMetricsManager {
opt_contentMetrics?: ContainerRegion): ContainerRegion;

/**
* Gets the width and the height of the flyout on the workspace in pixel
* coordinates. Returns 0 for the width and height if the workspace has a
* category toolbox instead of a simple toolbox.
* Gets the width and the height of the flyout in pixel
* coordinates. By default, will get metrics for either a simple flyout (owned
* directly by the workspace) or for the flyout owned by the toolbox. If you
* pass `opt_own` as `true` then only metrics for the simple flyout will be
* returned, and it will return 0 for the width and height if the workspace
* has a category toolbox instead of a simple toolbox.
*
* @param opt_own Whether to only return the workspace's own flyout.
* @param opt_own Whether to only return the workspace's own flyout metrics.
* @returns The width and height of the flyout.
*/
getFlyoutMetrics(opt_own?: boolean): ToolboxMetrics;
Expand All @@ -60,8 +63,7 @@ export interface IMetricsManager {
* Gets the width, height and position of the toolbox on the workspace in
* pixel coordinates. Returns 0 for the width and height if the workspace has
* a simple toolbox instead of a category toolbox. To get the width and height
* of a
* simple toolbox @see {@link IMetricsManager#getFlyoutMetrics}.
* of a simple toolbox, see {@link IMetricsManager#getFlyoutMetrics}.
*
* @returns The object with the width, height and position of the toolbox.
*/
Expand Down
14 changes: 8 additions & 6 deletions core/metrics_manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,14 @@ export class MetricsManager implements IMetricsManager {
}

/**
* Gets the width and the height of the flyout on the workspace in pixel
* coordinates. Returns 0 for the width and height if the workspace has a
* category toolbox instead of a simple toolbox.
* Gets the width and the height of the flyout in pixel
* coordinates. By default, will get metrics for either a simple flyout (owned
* directly by the workspace) or for the flyout owned by the toolbox. If you
* pass `opt_own` as `true` then only metrics for the simple flyout will be
* returned, and it will return 0 for the width and height if the workspace
* has a category toolbox instead of a simple toolbox.
*
* @param opt_own Whether to only return the workspace's own flyout.
* @param opt_own Whether to only return the workspace's own flyout metrics.
* @returns The width and height of the flyout.
*/
getFlyoutMetrics(opt_own?: boolean): ToolboxMetrics {
Expand All @@ -76,8 +79,7 @@ export class MetricsManager implements IMetricsManager {
* Gets the width, height and position of the toolbox on the workspace in
* pixel coordinates. Returns 0 for the width and height if the workspace has
* a simple toolbox instead of a category toolbox. To get the width and height
* of a
* simple toolbox @see {@link MetricsManager#getFlyoutMetrics}.
* of a simple toolbox, see {@link MetricsManager#getFlyoutMetrics}.
*
* @returns The object with the width, height and position of the toolbox.
*/
Expand Down