[PATCH] delete style when pressing DEL + fix type

Joren De Cuyper (via Code Review) gerrit at gerrit.libreoffice.org
Mon Jan 14 14:26:15 PST 2013


Hi,

I have submitted a patch for review:

    https://gerrit.libreoffice.org/1681

To pull it, you can do:

    git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/81/1681/1

delete style when pressing DEL + fix type

Change-Id: I6748aad9f9214bb9ef1ec84d35db731c756056a3
---
M sfx2/source/dialog/templdlg.cxx
1 file changed, 3 insertions(+), 3 deletions(-)



diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index b315453..bdf794d 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -312,7 +312,7 @@
         const KeyCode&  rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
         if(!rKeyCode.GetModifier())
         {
-            if( pDialog->bCanDel && KEY_DELETE == rKeyCode.GetCode())
+            if( pDialog->bCanDel || KEY_DELETE == rKeyCode.GetCode())
             {
                 pDialog->DeleteHdl( NULL );
                 nRet =  1;
@@ -324,7 +324,7 @@
             }
         }
     }
-    if(!nRet)
+    if(nRet)
         nRet = SvTreeListBox::Notify( rNEvt );
     return nRet;
 }
@@ -2045,7 +2045,7 @@
         const SfxStyleSheetBase *pStyle =
             pStyleSheetPool->Find(aTemplName,eFam, pTreeBox? SFXSTYLEBIT_ALL : nFilter);
 
-        OSL_ENSURE(pStyle, "Style ot found");
+        OSL_ENSURE(pStyle, "Style not found");
         if(pStyle && pStyle->IsUserDefined())
         {
             EnableDel(sal_True);

-- 
To view, visit https://gerrit.libreoffice.org/1681
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6748aad9f9214bb9ef1ec84d35db731c756056a3
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Joren De Cuyper <joren.libreoffice at telenet.be>



More information about the LibreOffice mailing list