[partition] Warnings-reduction
- use consistent size-formatting - needs an out-of-line virtual function
This commit is contained in:
parent
5b05110351
commit
bb3f4442f5
@ -9,11 +9,10 @@
|
|||||||
|
|
||||||
#include "ListPhysicalVolumeWidgetItem.h"
|
#include "ListPhysicalVolumeWidgetItem.h"
|
||||||
|
|
||||||
#include <kpmcore/util/capacity.h>
|
#include "core/SizeUtils.h"
|
||||||
|
|
||||||
ListPhysicalVolumeWidgetItem::ListPhysicalVolumeWidgetItem( const Partition* partition, bool checked )
|
ListPhysicalVolumeWidgetItem::ListPhysicalVolumeWidgetItem( const Partition* partition, bool checked )
|
||||||
: QListWidgetItem(
|
: QListWidgetItem( QString( "%1 | %2" ).arg( partition->deviceNode(), formatByteSize( partition->capacity() ) ) )
|
||||||
QString( "%1 | %2" ).arg( partition->deviceNode(), Capacity::formatByteSize( partition->capacity() ) ) )
|
|
||||||
, m_partition( partition )
|
, m_partition( partition )
|
||||||
{
|
{
|
||||||
setToolTip( partition->deviceNode() );
|
setToolTip( partition->deviceNode() );
|
||||||
@ -26,3 +25,5 @@ ListPhysicalVolumeWidgetItem::partition() const
|
|||||||
{
|
{
|
||||||
return m_partition;
|
return m_partition;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ListPhysicalVolumeWidgetItem::~ListPhysicalVolumeWidgetItem() {}
|
||||||
|
@ -18,6 +18,7 @@ class ListPhysicalVolumeWidgetItem : public QListWidgetItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ListPhysicalVolumeWidgetItem( const Partition* partition, bool checked );
|
ListPhysicalVolumeWidgetItem( const Partition* partition, bool checked );
|
||||||
|
~ListPhysicalVolumeWidgetItem() override;
|
||||||
|
|
||||||
const Partition* partition() const;
|
const Partition* partition() const;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user