ubuntu-touch-coreapps-reviewers team mailing list archive
-
ubuntu-touch-coreapps-reviewers team
-
Mailing list archive
-
Message #04338
Re: [Merge] lp:~nik90/ubuntu-clock-app/add-utility-backend into lp:ubuntu-clock-app
Review: Needs Information
some inline comments.
Diff comments:
>
> === added file 'backend/modules/Clock/Utility/filemanagement.cpp'
> --- backend/modules/Clock/Utility/filemanagement.cpp 1970-01-01 00:00:00 +0000
> +++ backend/modules/Clock/Utility/filemanagement.cpp 2015-08-19 15:18:24 +0000
> @@ -0,0 +1,40 @@
> +/*
> + * Copyright (C) 2015 Canonical Ltd
> + *
> + * This file is part of Ubuntu Clock App
> + *
> + * Ubuntu Clock App is free software: you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 3 as
> + * published by the Free Software Foundation.
> + *
> + * Ubuntu Clock App is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + *
> + * You should have received a copy of the GNU General Public License
> + * along with this program. If not, see <http://www.gnu.org/licenses/>.
> + */
> +
> +#include <QDir>
> +#include <QDebug>
> +
> +#include "filemanagement.h"
> +
> +FileManagement::FileManagement(QObject *parent):
> + QObject(parent)
> +{
> +}
> +
> +void FileManagement::deleteFile(const QString &dirName, const QString &fileName)
> +{
This file removal is a little scary to me. Can we convert it to method deleteAlarmSound ? It will be delete sound file only from specific folder, where custom sounds are located. It will give us also some level of abstraction: we will not care about directory strcture anymore. we will just specify alarm name.
> + QDir dir(dirName);
> +
> + // If directory doesn't exist, return
> + if (!dir.exists())
> + {
> + return;
> + }
> +
> + dir.remove(fileName);
> +}
--
https://code.launchpad.net/~nik90/ubuntu-clock-app/add-utility-backend/+merge/268490
Your team Ubuntu Clock Developers is subscribed to branch lp:ubuntu-clock-app.