[Libreoffice-commits] core.git: sfx2/source
Julien Nabet
serval2412 at yahoo.fr
Wed Feb 27 10:49:59 PST 2013
sfx2/source/control/templateremoteview.cxx | 23 -----------------------
1 file changed, 23 deletions(-)
New commits:
commit 4bdd78dc3122bdc1eaf85f05fc3cb1cb9afedf7d
Author: Julien Nabet <serval2412 at yahoo.fr>
Date: Wed Feb 27 19:42:48 2013 +0100
Remove unused parts and simplify
See http://nabble.documentfoundation.org/Cppcheck-quot-bContainsDate-quot-not-read-in-templateremoteview-cxx-sfx2-td4032416.html
Change-Id: I2369d728e431d5e802871fc0a173aacc90079798
diff --git a/sfx2/source/control/templateremoteview.cxx b/sfx2/source/control/templateremoteview.cxx
index 8b76094..acf0703 100644
--- a/sfx2/source/control/templateremoteview.cxx
+++ b/sfx2/source/control/templateremoteview.cxx
@@ -109,7 +109,6 @@ bool TemplateRemoteView::loadRepository (TemplateRepository* pItem, bool bRefres
uno::Reference< XRow > xRow( xResultSet, UNO_QUERY );
uno::Reference< XContentAccess > xContentAccess( xResultSet, UNO_QUERY );
- util::DateTime aDT;
std::vector<TemplateItemProperties> aItems;
sal_uInt16 nIdx = 0;
@@ -120,15 +119,6 @@ bool TemplateRemoteView::loadRepository (TemplateRepository* pItem, bool bRefres
// don't show hidden files or anything besides documents
if ( !bIsHidden || xRow->wasNull() )
{
- aDT = xRow->getTimestamp( ROW_DATE_MOD );
- bool bContainsDate = !xRow->wasNull();
-
- if ( !bContainsDate )
- {
- aDT = xRow->getTimestamp( ROW_DATE_CREATE );
- bContainsDate = !xRow->wasNull();
- }
-
OUString aContentURL = xContentAccess->queryContentIdentifierString();
OUString aTargetURL = xRow->getString( ROW_TARGET_URL );
bool bHasTargetURL = !xRow->wasNull() && !aTargetURL.isEmpty();
@@ -144,19 +134,6 @@ bool TemplateRemoteView::loadRepository (TemplateRepository* pItem, bool bRefres
TEMPLATE_THUMBNAIL_MAX_HEIGHT);
aTemplateItem.aName = xRow->getString( ROW_TITLE );
- if ( bHasTargetURL &&
- INetURLObject( aContentURL ).GetProtocol() == INET_PROT_VND_SUN_STAR_HIER )
- {
- ucbhelper::Content aCnt( aTargetURL, m_xCmdEnv, comphelper::getProcessComponentContext() );
-
- try
- {
- aCnt.getPropertyValue("DateModified") >>= aDT;
- }
- catch (...)
- {}
- }
-
pItem->insertTemplate(aTemplateItem);
aItems.push_back(aTemplateItem);
++nIdx;
More information about the Libreoffice-commits
mailing list