title: Problem with handling event on radio buttons in Android programming
body: <p>Hey guys have an application with using radio button as following codes</p>
  
  <pre><code>        default_mode =(RadioButton)findViewById(R.id.default_mode);
          warn_mode =(RadioButton)findViewById(R.id.warn_mode);
          grey_mode =(RadioButton)findViewById(R.id.grey_mode);
          QueGroup1 =(RadioGroup)findViewById(R.id.QueGroup1);
   QueGroup1.setOnCheckedChangeListener(new OnCheckedChangeListener() {
      public void onCheckedChanged(RadioGroup rg, int checkedId) {
          // TODO Auto-generated method stub
          for(int i=0; i&lt;rg.getChildCount(); i++) { 
  
              //RadioButton btn = (RadioButton) rg.getChildAt(i); 
              if(default_mode.getId() == checkedId) { 
                  default_method();
                  colorTouched();
  
                  return; 
              } 
              else if(warn_mode.getId() == checkedId) 
              { 
                  warn_method();
  
                  return;
              }
              else if(grey_mode.getId() == checkedId){
                  grey_method();
  
                  return;
              }
          }
      }
  });
  </code></pre>
  
  <p>The problem is when I selected on default_mode then selected on warn_mode </p>
  
  <p>the method named colorTouched(); is still working. What I really want to know is how to stop the method from other's radio button. Ex. If I select warn_mode the method warn_method() must working only.  </p>
  
  <p>Thanks in advance :))) </p>