Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion deepin-devicemanager/src/Widget/CmdButtonWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ void CmdButtonWidget::paintEvent(QPaintEvent *event)
cg = DPalette::Inactive;
}

this->rect().setWidth(808);
QRect rect = this->rect();
rect.setWidth(808);
// 开始绘制边框 *********************************************************
Expand Down
3 changes: 1 addition & 2 deletions deepin-devicemanager/src/Widget/UrlChooserEdit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,9 @@ void UrlChooserEdit::checkLocalFolder(const QString &path)
{
qCDebug(appLog) << "Checking if folder is local:" << path;

Q_UNUSED(path);
bool isLocal = true;
mp_urlEdit->setAlert(false);
QStorageInfo info(mp_folderPath); //获取路径信息
QStorageInfo info(path); //获取路径信息
qCInfo(appLog) << __func__ <<info.device();
if (!info.isValid() || !info.device().startsWith("/dev/")) { //判断路径信息是不是本地路径
qCWarning(appLog) << "Selected folder is not local";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ TEST_F(UT_UrlChooserEdit, UT_UrlChooserEdit_slotChooseUrl)
TEST_F(UT_UrlChooserEdit, UT_UrlChooserEdit_checkLocalFolder_001)
{
m_UrlChooserEdit->mp_folderPath = "smb://10.4.10.4";
m_UrlChooserEdit->checkLocalFolder("/home");
m_UrlChooserEdit->checkLocalFolder("smb://10.4.10.4");
EXPECT_TRUE(m_UrlChooserEdit->mp_urlEdit->isAlert());
}

Expand Down
Loading