@@ -290,7 +290,7 @@ export class MdRadioGroup implements AfterContentInit, ControlValueAccessor {
290290 '[class.mat-radio-checked]' : 'checked' ,
291291 '[class.mat-radio-disabled]' : 'disabled' ,
292292 '[attr.id]' : 'id' ,
293- }
293+ } ,
294294 changeDetection : ChangeDetectionStrategy . OnPush ,
295295} )
296296export class MdRadioButton implements OnInit , AfterViewInit , OnDestroy {
@@ -327,13 +327,14 @@ export class MdRadioButton implements OnInit, AfterViewInit, OnDestroy {
327327 private _elementRef : ElementRef ,
328328 private _renderer : Renderer ,
329329 private _changeDetector : ChangeDetectorRef ,
330- public radioDispatcher : UniqueSelectionDispatcher ) {
330+ private _focusOriginMonitor : FocusOriginMonitor ,
331+ private _radioDispatcher : UniqueSelectionDispatcher ) {
331332 // Assertions. Ideally these should be stripped out by the compiler.
332333 // TODO(jelbourn): Assert that there's no name binding AND a parent radio group.
333334
334335 this . radioGroup = radioGroup ;
335336
336- radioDispatcher . listen ( ( id : string , name : string ) => {
337+ _radioDispatcher . listen ( ( id : string , name : string ) => {
337338 if ( id != this . id && name == this . name ) {
338339 this . checked = false ;
339340 }
@@ -430,22 +431,9 @@ export class MdRadioButton implements OnInit, AfterViewInit, OnDestroy {
430431 this . _disabled = ( value != null && value !== false ) ? true : null ;
431432 }
432433
433- /**
434- * Event emitted when the checked state of this radio button changes.
435- * Change events are only emitted when the value changes due to user interaction with
436- * the radio button (the same behavior as `<input type-"radio">`).
437- */
438- @Output ( )
439- change : EventEmitter < MdRadioChange > = new EventEmitter < MdRadioChange > ( ) ;
440-
441434 /** The parent radio group. May or may not be present. */
442435 radioGroup : MdRadioGroup ;
443436
444- /** ID of the native input element inside `<md-radio-button>` */
445- get inputId ( ) : string {
446- return `${ this . id } -input` ;
447- }
448-
449437 /** Whether this radio is checked. */
450438 private _checked : boolean = false ;
451439
@@ -467,26 +455,6 @@ export class MdRadioButton implements OnInit, AfterViewInit, OnDestroy {
467455 /** Reference to the current focus ripple. */
468456 private _focusedRippleRef : RippleRef ;
469457
470- /** The native `<input type=radio>` element */
471- @ViewChild ( 'input' ) _inputElement : ElementRef ;
472-
473- constructor ( @Optional ( ) radioGroup : MdRadioGroup ,
474- private _elementRef : ElementRef ,
475- private _renderer : Renderer ,
476- private _focusOriginMonitor : FocusOriginMonitor ,
477- private _radioDispatcher : UniqueSelectionDispatcher ) {
478- // Assertions. Ideally these should be stripped out by the compiler.
479- // TODO(jelbourn): Assert that there's no name binding AND a parent radio group.
480-
481- this . radioGroup = radioGroup ;
482-
483- _radioDispatcher . listen ( ( id : string , name : string ) => {
484- if ( id != this . id && name == this . name ) {
485- this . checked = false ;
486- }
487- } ) ;
488- }
489-
490458 /** Focuses the radio button. */
491459 focus ( ) : void {
492460 this . _focusOriginMonitor . focusVia ( this . _inputElement . nativeElement , this . _renderer , 'keyboard' ) ;
0 commit comments