Repaired some bugs in Rule Editor