[Haiku-commits] r31235 - haiku/trunk/src/add-ons/disk_systems/intel

bonefish at mail.berlios.de bonefish at mail.berlios.de
Thu Jun 25 17:36:01 CEST 2009


Author: bonefish
Date: 2009-06-25 17:35:59 +0200 (Thu, 25 Jun 2009)
New Revision: 31235
ViewCVS: http://svn.berlios.de/viewcvs/haiku?rev=31235&view=rev

Modified:
   haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.cpp
   haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.h
Log:
Patch by Bryce Groff: Implemented DeleteChild().


Modified: haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.cpp
===================================================================
--- haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.cpp	2009-06-25 15:35:16 UTC (rev 31234)
+++ haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.cpp	2009-06-25 15:35:59 UTC (rev 31235)
@@ -364,6 +364,7 @@
 	PartitionType type;
 	if (!type.SetType(typeString) || type.IsEmpty())
 		return B_BAD_VALUE;
+
 	if (type.IsExtended() && fPartitionMap.ExtendedPartitionIndex() >= 0)
 		return B_BAD_VALUE;
 
@@ -556,3 +557,13 @@
 	return B_OK;
 }
 
+
+// DeleteChild
+status_t
+PartitionMapHandle::DeleteChild(BMutablePartition* child)
+{
+	BMutablePartition* parent = child->Parent();
+	status_t error = parent->DeleteChild(child);
+
+	return error;
+}

Modified: haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.h
===================================================================
--- haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.h	2009-06-25 15:35:16 UTC (rev 31234)
+++ haiku/trunk/src/add-ons/disk_systems/intel/PartitionMapAddOn.h	2009-06-25 15:35:59 UTC (rev 31235)
@@ -62,6 +62,7 @@
 									const char* type, const char* name,
 									const char* parameters,
 									BMutablePartition** child);
+	virtual status_t			DeleteChild(BMutablePartition* child);
 
 private:
 			PartitionMap		fPartitionMap;




More information about the Haiku-commits mailing list