Skip to content
This repository has been archived by the owner on Jul 14, 2019. It is now read-only.
/ Miam-Player Public archive

Commit

Permalink
Update build
Browse files Browse the repository at this point in the history
  • Loading branch information
MBach committed Oct 28, 2018
1 parent 0fc8043 commit 76d1e08
Show file tree
Hide file tree
Showing 67 changed files with 32 additions and 151 deletions.
4 changes: 2 additions & 2 deletions lib/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ I know these files shouldn't belong here. But it keeps things way more simple to

These files are used for compiling subproject `MiamCore`. You can also rebuild these files for Windows/OSX if you wish.

###Folders *debug* and *release* (x64 only)
- Files for Windows. Built with MSVC2013
###Folders *release* (x64 only)
- Files for Windows. Built with MSVC2015-MSVC2017

###Folder *osx*
- Contains only `libtag.dylib`
Expand Down
Binary file removed lib/debug/win-x64/OpenAL32.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/QtAV1.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/QtAV1.lib
Binary file not shown.
Binary file removed lib/debug/win-x64/avcodec-57.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/avdevice-57.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/avfilter-6.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/avformat-57.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/avresample-3.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/avutil-55.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/chromaprint.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/swresample-2.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/swscale-4.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/tag.dll
Binary file not shown.
Binary file removed lib/debug/win-x64/tag.lib
Binary file not shown.
Binary file modified lib/release/win-x64/OpenAL32.dll
Binary file not shown.
Binary file modified lib/release/win-x64/QtAV1.dll
Binary file not shown.
Binary file modified lib/release/win-x64/QtAV1.lib
Binary file not shown.
Binary file modified lib/release/win-x64/avcodec-57.dll
Binary file not shown.
Binary file modified lib/release/win-x64/avdevice-57.dll
Binary file not shown.
Binary file modified lib/release/win-x64/avfilter-6.dll
Binary file not shown.
Binary file modified lib/release/win-x64/avformat-57.dll
Binary file not shown.
Binary file modified lib/release/win-x64/avresample-3.dll
Binary file not shown.
Binary file modified lib/release/win-x64/avutil-55.dll
Binary file not shown.
Binary file modified lib/release/win-x64/swresample-2.dll
Binary file not shown.
Binary file modified lib/release/win-x64/swscale-4.dll
Binary file not shown.
6 changes: 3 additions & 3 deletions miam-player.pro
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ SUBDIRS += src/core \
src/tageditor \
src/player

RESOURCES += src/player/mp.qrc \
src/tabplaylists/mp.qrc \
src/tageditor/player.qrc
RESOURCES += src/player/player.qrc \
src/tabplaylists/tabPlaylists.qrc \
src/tageditor/tageditor.qrc
10 changes: 2 additions & 8 deletions src/core/filehelper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,6 @@ QString FileHelper::artistAlbum() const
}
break;
case EXT_ASF:
qDebug() << Q_FUNC_INFO << "Not yet implemented for ASF file";
break;
case EXT_FLAC:
artAlb = this->extractFlacFeature("ALBUMARTIST");
Expand Down Expand Up @@ -248,8 +247,6 @@ void FileHelper::setArtistAlbum(const QString &artistAlbum)
break;
}
case EXT_MPC:
//mpcFile = static_cast<MPC::File*>(f);
qDebug() << Q_FUNC_INFO << "Not implemented for MPC";
break;
case EXT_MP3:{
TagLib::MPEG::File *mpegFile = static_cast<TagLib::MPEG::File*>(_file);
Expand All @@ -264,21 +261,18 @@ void FileHelper::setArtistAlbum(const QString &artistAlbum)
tif->setText(artistAlbum.toStdString().data());
tag->addFrame(tif);
} else if (mpegFile->hasID3v1Tag()) {
qDebug() << Q_FUNC_INFO << "Not implemented for ID3v1Tag";

}
break;
}
case EXT_OGG: {
TagLib::Ogg::XiphComment *xiphComment = static_cast<TagLib::Ogg::XiphComment*>(_file->tag());
if (xiphComment) {
xiphComment->addField("ALBUMARTIST", artistAlbum.toStdString().data());
} else {
qDebug() << Q_FUNC_INFO << "Not implemented for this OGG file";
}
}
break;
}
default:
qDebug() << Q_FUNC_INFO << "Not implemented for this type of file";
break;
}
}
Expand Down
1 change: 0 additions & 1 deletion src/core/library/jumptowidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ bool JumpToWidget::eventFilter(QObject *obj, QEvent *event)

QSize JumpToWidget::sizeHint() const
{
//qDebug() << Q_FUNC_INFO << QSize(20, _view->height());
return QSize(20, _view->height());
}

Expand Down
16 changes: 2 additions & 14 deletions src/core/mediaplayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,16 @@ MediaPlayer::MediaPlayer(QObject *parent)
, _stopAfterCurrent(false)
{
connect(_localPlayer, &QtAV::AVPlayer::stopped, this, [=]() {
//qDebug() << "QtAV::AVPlayer::stopped";
this->setState(QMediaPlayer::StoppedState);
});

connect(_localPlayer, &QtAV::AVPlayer::loaded, this, [=]() {
//qDebug() << "QtAV::AVPlayer::loaded";
_localPlayer->audio()->setVolume(Settings::instance()->volume());
emit currentMediaChanged(_localPlayer->file());
this->setState(QMediaPlayer::PlayingState);
});

connect(_localPlayer, &QtAV::AVPlayer::paused, this, [=](bool) {
//qDebug() << "QtAV::AVPlayer::paused" << b;
this->setState(QMediaPlayer::PausedState);
});

Expand Down Expand Up @@ -133,13 +130,9 @@ void MediaPlayer::playMediaContent(const QMediaContent &mc)
} else {
// Find remote player attached to mediaContent
_remotePlayer = _remotePlayers.value(mc.canonicalUrl().host());
qDebug() << Q_FUNC_INFO << "about to play remote track" << mc.canonicalUrl().host() << _remotePlayer;
if (_remotePlayer) {
qDebug() << Q_FUNC_INFO << "about to play remote track" << mc.canonicalUrl();
_remotePlayer->play(mc.canonicalUrl());
} else {
qDebug() << Q_FUNC_INFO << "couldn't get remote player for" << mc.canonicalUrl();
}
}
}
this->setVolume(Settings::instance()->volume());
}
Expand Down Expand Up @@ -248,7 +241,6 @@ void MediaPlayer::seekForward()

void MediaPlayer::skipBackward()
{
qDebug() << Q_FUNC_INFO << playlist();
if (!_playlist) {
return;
}
Expand Down Expand Up @@ -289,12 +281,10 @@ void MediaPlayer::play()
{
// Check if it's possible to play tracks first
if (!_playlist) {
qDebug() << Q_FUNC_INFO << "no playlist!";
return;
}
QMediaContent mc = _playlist->media(_playlist->currentIndex());
if (mc.isNull()) {
qDebug() << Q_FUNC_INFO << "media content is null!";
return;
}
this->playMediaContent(mc);
Expand All @@ -316,9 +306,7 @@ void MediaPlayer::stop()
/** Activate or desactive audio output. */
void MediaPlayer::toggleMute() const
{
if (_remotePlayer) {
qDebug() << Q_FUNC_INFO << "not yet implemented for remote players";
} else {
if (!_remotePlayer) {
_localPlayer->audio()->setMute(!_localPlayer->audio()->isMute());
}
}
Expand Down
6 changes: 0 additions & 6 deletions src/core/model/sqldatabase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,6 @@ uint SqlDatabase::insertIntoTablePlaylists(const PlaylistDAO &playlist, const QS
this->setPragmas();
}

qDebug() << Q_FUNC_INFO << tracks;

static std::uniform_int_distribution<uint> tt;
this->transaction();
uint id = 0;
Expand Down Expand Up @@ -513,7 +511,6 @@ void SqlDatabase::updateTrack(const QString &absFilePath)
{
FileHelper fh(absFilePath);
if (!fh.isValid()) {
qDebug() << Q_FUNC_INFO << "file is not valid, won't be updated";
return;
}

Expand Down Expand Up @@ -569,8 +566,6 @@ void SqlDatabase::updateTracks(const QStringList &oldPaths, const QStringList &n
transaction();
Q_ASSERT(oldPaths.size() == newPaths.size());

//qDebug() << Q_FUNC_INFO << "oldPaths" << oldPaths;
//qDebug() << Q_FUNC_INFO << "newPaths" << newPaths;
for (int i = 0; i < newPaths.size(); i++) {
QString newPath = newPaths.at(i);
QString oldPath = oldPaths.at(i);
Expand Down Expand Up @@ -632,7 +627,6 @@ void SqlDatabase::saveFileRef(const QString &absFilePath)
{
FileHelper fh(absFilePath);
if (!fh.isValid()) {
qDebug() << Q_FUNC_INFO << "file is not valid, won't be saved:" << absFilePath;
return;
}

Expand Down
2 changes: 0 additions & 2 deletions src/core/musicsearchengine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,6 @@ void MusicSearchEngine::doSearch()
void MusicSearchEngine::watchForChanges()
{
if (isScanning) {
qDebug() << Q_FUNC_INFO << "the filesystem is already being analyzed by another process";
return;
}

Expand Down Expand Up @@ -177,7 +176,6 @@ void MusicSearchEngine::watchForChanges()

// Process in reverse mode to clean cache: from database file and check if entry exists in database
QSqlQuery cache("SELECT * FROM filesystem", db);
qDebug() << Q_FUNC_INFO << "SELECT * FROM filesystem";
cache.setForwardOnly(true);
if (cache.exec()) {
QStringList oldLocations;
Expand Down
4 changes: 1 addition & 3 deletions src/core/settingsprivate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -525,9 +525,7 @@ void SettingsPrivate::addMusicLocations(const QList<QDir> &dirs)
for (QDir d : dirs) {
if (!old.contains(QDir::toNativeSeparators(d.absolutePath()))) {
locations << QDir::toNativeSeparators(d.absolutePath());
} else {
qDebug() << Q_FUNC_INFO << old << "already contains" << QDir::toNativeSeparators(d.absolutePath());
}
}
}
QStringList newLocations(old);
newLocations.append(locations);
Expand Down
1 change: 0 additions & 1 deletion src/core/styling/miamstyleditemdelegate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ void MiamStyledItemDelegate::paint(QPainter *p, const QStyleOptionViewItem &opt,
p->drawLine(o.rect.x(), o.rect.y() + o.rect.height(), o.rect.x() + o.rect.width(), o.rect.y() + o.rect.height());
}
} else {
//qDebug() << Q_FUNC_INFO << o.text;
style->drawPrimitive(QStyle::PE_PanelItemViewItem, &o, p, o.widget);
}
p->restore();
Expand Down
2 changes: 1 addition & 1 deletion src/cover-fetcher/coverfetcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ void CoverFetcher::fetch(SelectedTracksModel *selectedTracksModel)
QUrl url = cp->query(artistAlbum, album);
QNetworkRequest request(url);
request.setAttribute(QNetworkRequest::User, CoverArtProvider::FO_Search);
request.setHeader(QNetworkRequest::UserAgentHeader, "MiamPlayer/0.8.1 ( https://www.miam-player.org/ )" );
request.setHeader(QNetworkRequest::UserAgentHeader, "MiamPlayer/0.9.0 ( https://github.com/MBach/Miam-Player )" );
QNetworkReply *n = _manager->get(request);
n->setProperty("type", cp->type());
n->setProperty("requestType", CoverArtProvider::FO_Search);
Expand Down
2 changes: 1 addition & 1 deletion src/cover-fetcher/providers/musicbrainzprovider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ void MusicBrainzProvider::fetchReleases(const QString &album, const QByteArray &
/// FIXME: find a way to get the 500px thumbnail and to automatically download the large one after
QUrl url = this->album(it.value());
QNetworkRequest request(url);
request.setHeader(QNetworkRequest::UserAgentHeader, "MiamPlayer/0.8.1 ( http://www.miam-player.org/ )" );
request.setHeader(QNetworkRequest::UserAgentHeader, "MiamPlayer/0.9.0 ( https://github.com/MBach/Miam-Player )" );
QNetworkReply *reply = _manager->get(request);
reply->setProperty("type", this->type());
reply->setProperty("requestType", FO_DownloadCover);
Expand Down
2 changes: 1 addition & 1 deletion src/library/library.pro
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ HEADERS += albumitem.h \
FORMS += libraryorderdialog.ui
CONFIG += c++11
CONFIG(debug, debug|release) {
win32: LIBS += -L$$OUT_PWD/../core/debug/ -lmiam-core -L$$OUT_PWD/../cover-fetcher/release/ -lmiam-coverfetcher
win32: LIBS += -L$$OUT_PWD/../core/debug/ -lmiam-core -L$$OUT_PWD/../cover-fetcher/debug/ -lmiam-coverfetcher
OBJECTS_DIR = debug/.obj
MOC_DIR = debug/.moc
RCC_DIR = debug/.rcc
Expand Down
1 change: 0 additions & 1 deletion src/library/libraryitemmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ void LibraryItemModel::load(const QString &)

// Add artist
if (_artists.contains(artistItem->hash())) {
//qDebug() << "hash found:" << artistItem->hash() << "for" << artistItem->text() ;
auto it = _artists.find(artistItem->hash());
delete artistItem;
artistItem = (*it);
Expand Down
5 changes: 0 additions & 5 deletions src/library/librarytreeview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,19 +151,15 @@ void LibraryTreeView::setExpandedCover(const QModelIndex &index)
{
QStandardItem *item = _libraryModel->itemFromIndex(_proxyModel->mapToSource(index));
if (item->type() == Miam::IT_Album && Settings::instance()->isCoverBelowTracksEnabled()) {
qDebug() << Q_FUNC_INFO;
QImage *image = nullptr;
AlbumItem *albumItem = static_cast<AlbumItem*>(item);
if (albumItem->data(Miam::DF_InternalCover).toString().isEmpty()) {

QString coverPath = albumItem->data(Miam::DF_CoverPath).toString();
qDebug() << Q_FUNC_INFO << "loading external cover" << coverPath;
if (!coverPath.isEmpty()) {
image = new QImage(coverPath);
}
} else {
qDebug() << Q_FUNC_INFO << "loading internal cover";

FileHelper fh(albumItem->data(Miam::DF_InternalCover).toString());
std::unique_ptr<Cover> cover(fh.extractCover());
if (cover) {
Expand Down Expand Up @@ -212,7 +208,6 @@ void LibraryTreeView::scrollToLetter(const QString &letter)
void LibraryTreeView::updateSelectedTracks()
{
/// Like the tagEditor, it's easier to proceed with complete clean/rebuild from dabatase
qDebug() << Q_FUNC_INFO;
model()->load();
}

Expand Down
2 changes: 1 addition & 1 deletion src/player/config/mp.rc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ IDI_ICON1 ICON DISCARDABLE "../../core/mp.ico"
// Executable version information.
1 VERSIONINFO
FILEVERSION 1,0,0,0
PRODUCTVERSION 0,8,1,20161229
PRODUCTVERSION 0,9,0,20181028
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand Down
2 changes: 0 additions & 2 deletions src/player/dialogs/customizeoptionsdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,6 @@ void CustomizeOptionsDialog::initShortcuts()
emit shortcut->editingFinished();
});
connect(reset, &QPushButton::clicked, this, [=]() {
qDebug() << Q_FUNC_INFO << shortcut->objectName() << QKeySequence(defaultShortcutMap.value(shortcut->objectName()).toString());
shortcut->setKeySequence(QKeySequence(defaultShortcutMap.value(shortcut->objectName()).toString()));
emit shortcut->editingFinished();
});
Expand Down Expand Up @@ -494,7 +493,6 @@ void CustomizeOptionsDialog::togglePlugin(QTableWidgetItem *item)

void CustomizeOptionsDialog::toggleRemoteControl(bool enabled)
{
qDebug() << Q_FUNC_INFO;
remoteControlLabelPort->setEnabled(enabled);
remoteControlPortSpinBox->setEnabled(enabled);
SettingsPrivate::instance()->setRemoteControlEnabled(enabled);
Expand Down
4 changes: 0 additions & 4 deletions src/player/dialogs/customizethemedialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,6 @@ void CustomizeThemeDialog::setupActions()

// Change big cover opacity
connect(radioButtonEnableBigCover, &QRadioButton::toggled, [=](bool b) {
qDebug() << Q_FUNC_INFO;
settings->setCoverBelowTracksEnabled(b);
labelBigCoverOpacity->setEnabled(b);
spinBoxBigCoverOpacity->setEnabled(b);
Expand Down Expand Up @@ -486,7 +485,6 @@ void CustomizeThemeDialog::showColorDialog()

void CustomizeThemeDialog::toggleCustomColors(bool enabled)
{
qDebug() << Q_FUNC_INFO << enabled;
this->toggleCustomColorsGridLayout(customColorsGridLayout, enabled);

labelOverrideTextColor->setEnabled(enabled);
Expand All @@ -503,8 +501,6 @@ void CustomizeThemeDialog::toggleCustomColors(bool enabled)

void CustomizeThemeDialog::toggleCustomTextColors(bool enabled)
{
qDebug() << Q_FUNC_INFO << enabled;

this->toggleCustomColorsGridLayout(customTextColorsGridLayout, enabled);
this->toggleCustomColorsReflector(fontColorWidget, selectedFontColorWidget, enabled);
}
1 change: 0 additions & 1 deletion src/player/dialogs/customizethemetaglineedit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,5 @@ bool CustomizeThemeTagLineEdit::eventFilter(QObject *obj, QEvent *event)
void CustomizeThemeTagLineEdit::closeTagButton(TagButton *t)
{
TagLineEdit::closeTagButton(t);
qDebug() << Q_FUNC_INFO << this->toStringList();
emit taglistHasChanged(this->toStringList());
}
2 changes: 1 addition & 1 deletion src/player/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

#define COMPANY "MmeMiamMiam"
#define SOFT "MiamPlayer"
#define VERSION "0.8.1"
#define VERSION "0.9.0"

#include <settingsprivate.h>
#include "styling/miamstyle.h"
Expand Down
10 changes: 2 additions & 8 deletions src/player/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ void MainWindow::setupActions()
this->syncLibrary(QStringList(), settingsPrivate->musicLocations());
});
connect(actionShowHelp, &QAction::triggered, this, [=]() {
QDesktopServices::openUrl(QUrl("http://miam-player.org/wiki/index.php"));
QDesktopServices::openUrl(QUrl("https://github.com/MBach/Miam-Player/wiki"));
});

// Load music
Expand All @@ -224,10 +224,7 @@ void MainWindow::setupActions()
if (_currentView && _currentView->viewProperty(Settings::VP_HasAreaForRescan)) {
_currentView->setMusicSearchEngine(worker);
}
qDebug() << Q_FUNC_INFO << "create new instance of file system watcher";
} else {
qDebug() << Q_FUNC_INFO << "delete any instance of file system watcher";
}
}
});

connect(settingsPrivate, &SettingsPrivate::fontHasChanged, this, [=](SettingsPrivate::FontFamily ff) {
Expand All @@ -237,7 +234,6 @@ void MainWindow::setupActions()
});

connect(settingsPrivate, &SettingsPrivate::remoteControlChanged, this, [=](bool enabled, uint port) {
qDebug() << Q_FUNC_INFO;
if (enabled) {
if (_remoteControl) {
_remoteControl->changeServerPort(port);
Expand Down Expand Up @@ -321,7 +317,6 @@ bool MainWindow::event(QEvent *e)
if (!this->menuBar()->isVisible()) {
QKeyEvent *keyEvent = static_cast<QKeyEvent*>(e);
if (keyEvent->key() == Qt::Key_Alt) {
qDebug() << Q_FUNC_INFO << "Alt was pressed";
this->setProperty("altKey", true);
this->toggleMenuBar(false);
// Reactivate shortcuts on the menuBar
Expand All @@ -339,7 +334,6 @@ bool MainWindow::event(QEvent *e)
} else if (e->type() == QEvent::KeyRelease) {
QKeyEvent *keyEvent = static_cast<QKeyEvent*>(e);
if (this->property("altKey").toBool() && keyEvent->key() == Qt::Key_Alt) {
qDebug() << Q_FUNC_INFO << "Alt was released";
this->menuBar()->show();
this->menuBar()->setFocus();
this->setProperty("altKey", false);
Expand Down
Loading

0 comments on commit 76d1e08

Please sign in to comment.