~carlos-mazieri/ubuntu-filemanager-app/model

« back to all changes in this revision

Viewing changes to folderlistmodel/location.cpp

  • Committer: carlos-mazieri
  • Date: 2014-05-24 11:44:38 UTC
  • Revision ID: carlos.mazieri@gmail.com-20140524114438-y3v8guja1snwmiy9
remade C++ UI

Show diffs side-by-side

added added

removed removed

Lines of Context:
66
66
 
67
67
bool Location::isRoot() const
68
68
{
69
 
     return m_info->isRoot();
 
69
     return m_info ? m_info->isRoot() : false;
70
70
}
71
71
 
72
72
 
78
78
 
79
79
bool Location::isReadable() const
80
80
{
81
 
    return m_info->isContentReadable();
 
81
    return m_info ? m_info->isContentReadable() : false;
82
82
}
83
83
 
84
84
void Location::setFromInfoItem(const DirItemInfo &itemInfo)
98
98
 
99
99
QString Location::urlPath() const
100
100
{
101
 
    return m_info->urlPath();
 
101
    return m_info ? m_info->urlPath(): QString();
102
102
}
103
103
 
104
104