File indexing completed on 2024-05-12 04:51:02

0001 /*
0002     SPDX-FileCopyrightText: 2011 Michal Malek <michalm@jabster.pl>
0003     SPDX-FileCopyrightText: 1998-2007 Sebastian Trueg <trueg@k3b.org>
0004 
0005     SPDX-License-Identifier: GPL-2.0-or-later
0006 */
0007 
0008 #include "k3bbootitem.h"
0009 #include "k3bdatadoc.h"
0010 #include "k3bdiritem.h"
0011 #include "k3b_i18n.h"
0012 
0013 namespace K3b {
0014 
0015 BootItem::BootItem( const QString& fileName, DataDoc& doc, const QString& k3bName )
0016     : FileItem( fileName, doc, k3bName, ItemFlags(FILE|BOOT_IMAGE) ),
0017       m_noBoot(false),
0018       m_bootInfoTable(false),
0019       m_loadSegment(0),
0020       m_loadSize(0),
0021       m_imageType(FLOPPY)
0022 {
0023     setExtraInfo( i18n("El Torito Boot image") );
0024 }
0025 
0026 
0027 BootItem::BootItem( const BootItem& item )
0028     : FileItem( item ),
0029       m_noBoot( item.m_noBoot ),
0030       m_bootInfoTable( item.m_bootInfoTable ),
0031       m_loadSegment( item.m_loadSegment ),
0032       m_loadSize( item.m_loadSize ),
0033       m_imageType( item.m_imageType ),
0034       m_tempPath( item.m_tempPath )
0035 {
0036 }
0037 
0038 
0039 BootItem::~BootItem()
0040 {
0041     take();
0042 }
0043 
0044 
0045 DataItem* BootItem::copy() const
0046 {
0047     return new BootItem( *this );
0048 }
0049 
0050 } // namespace K3b