| 79 | ******************************************************************************/ |
| 80 | |
| 81 | bool CmdAttributeEdit::performExecute() { |
| 82 | bool modified = false; |
| 83 | // Set type/value/unit before key for exception safety (setTypeValueUnit() can |
| 84 | // throw, but setKey() not)! |
| 85 | if (mAttribute.setTypeValueUnit(*mNewType, mNewValue, mNewUnit)) { |
| 86 | modified = true; |
| 87 | } |
| 88 | if (mAttribute.setKey(mNewKey)) { |
| 89 | modified = true; |
| 90 | } |
| 91 | return modified; |
| 92 | } |
| 93 | |
| 94 | void CmdAttributeEdit::performUndo() { |
| 95 | mAttribute.setTypeValueUnit(*mOldType, mOldValue, mOldUnit); |
nothing calls this directly
no test coverage detected