mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-17 17:22:42 -05:00
Fixing the checked variable in radio buttons (#13909)
* Fixing the checked variable in radio buttons * Emitting the checked state of radio button. * Adding onChanged event to radioButtons (exposing it) Deprecating onClick event for radioButtons Fixing radio button stubs * Made some type fixes * Firing event in checked event setter * updating azdata-test to 1.1 in arc extension * Some logic fixes in checked setter * added proper typings and updated package version for azdata-data * Renamed the event to onDidChangeCheckedState * Fixed deprecation message * Fixed broken Schema compare stubs
This commit is contained in:
@@ -1271,6 +1271,7 @@ class RadioButtonWrapper extends ComponentWrapper implements azdata.RadioButtonC
|
||||
super(proxy, handle, ModelComponentTypes.RadioButton, id);
|
||||
this.properties = {};
|
||||
this._emitterMap.set(ComponentEventType.onDidClick, new Emitter<any>());
|
||||
this._emitterMap.set(ComponentEventType.onDidChange, new Emitter<boolean>());
|
||||
}
|
||||
|
||||
public get name(): string {
|
||||
@@ -1304,6 +1305,11 @@ class RadioButtonWrapper extends ComponentWrapper implements azdata.RadioButtonC
|
||||
let emitter = this._emitterMap.get(ComponentEventType.onDidClick);
|
||||
return emitter && emitter.event;
|
||||
}
|
||||
|
||||
public get onDidChangeCheckedState(): vscode.Event<boolean> {
|
||||
let emitter = this._emitterMap.get(ComponentEventType.onDidChange);
|
||||
return emitter && emitter.event;
|
||||
}
|
||||
}
|
||||
|
||||
class TextComponentWrapper extends ComponentWrapper implements azdata.TextComponentProperties {
|
||||
|
||||
Reference in New Issue
Block a user