File indexing completed on 2024-05-12 05:00:23

0001 /*
0002     This file is part of the KDE project.
0003 
0004     SPDX-FileCopyrightText: 2020 Stefano Crocco <stefano.crocco@alice.it>
0005 
0006     SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0007 */
0008 #include <KParts/ReadOnlyPart>
0009 
0010 #include "implementations/konqbrowserwindowinterface.h"
0011 #include "konqmainwindow.h"
0012 #include "urlloader.h"
0013 #include "konqview.h"
0014 
0015 KonqBrowserWindowInterface::KonqBrowserWindowInterface(KonqMainWindow *mainWindow, KParts::ReadOnlyPart *part):
0016     BrowserInterface(mainWindow), m_mainWindow(mainWindow), m_part(part)
0017 {
0018 }
0019 
0020 void KonqBrowserWindowInterface::toggleCompleteFullScreen(bool on)
0021 {
0022     m_mainWindow->toggleCompleteFullScreen(on);
0023 }
0024 
0025 bool KonqBrowserWindowInterface::isCorrectPartForLocalFile(KParts::ReadOnlyPart *part, const QString &path)
0026 {
0027     return part->metaData().pluginId() == UrlLoader::partForLocalFile(path);
0028 }