Lines Matching defs:partition

66 	virtual bool Visit(BPartition* partition, int32 level);
77 virtual bool Visit(BPartition* partition, int32 level);
187 BPartition* partition;
189 if (fDDRoster.GetPartitionWithID(id, &device, &partition) == B_OK) {
190 if (!partition->IsMounted()) {
191 if (partition->Mount() < B_OK) {
192 _SetStatusMessage(B_TRANSLATE("The partition can't be "
193 "mounted. Please choose a different partition."));
197 if (partition->GetMountPoint(&targetDirectory) != B_OK) {
238 BPartition *partition = NULL;
241 fDDRoster.VisitEachMountedPartition(&srcVisitor, &device, &partition);
244 fDDRoster.VisitEachPartition(&targetVisitor, &device, &partition);
345 BPartition* partition;
354 ERR("bad source or target partition ID\n");
361 &partition) == B_OK) {
362 if (!partition->IsMounted()) {
363 if ((err = partition->Mount()) < B_OK) {
369 if ((err = partition->GetVolume(&targetVolume)) != B_OK) {
373 if ((err = partition->GetMountPoint(&targetDirectory)) != B_OK) {
408 if (fDDRoster.GetPartitionWithID(sourcePartitionID, &device, &partition)
410 if ((err = partition->GetMountPoint(&srcDirectory)) != B_OK) {
795 make_partition_label(BPartition* partition, char* label, char* menuLabel,
799 string_for_size(partition->Size(), size, sizeof(size));
802 partition->GetPath(&path);
805 const char* type = partition->ContentType();
809 sprintf(label, "%s - %s [%s] (%s)", partition->ContentName().String(), size,
812 sprintf(label, "%s - %s [%s]", partition->ContentName().String(), size,
816 sprintf(menuLabel, "%s - %s", partition->ContentName().String(), size);
836 SourceVisitor::Visit(BPartition *partition, int32 level)
840 if (partition->ContentType() == NULL)
844 if (partition->IsMounted()) {
846 if (partition->GetMountPoint(&mountPoint) != B_OK)
852 && strcmp(partition->ContentType(), kPartitionTypeBFS) != 0) {
853 // Except only BFS partitions, except this is the boot partition
865 make_partition_label(partition, label, menuLabel, false);
866 PartitionMenuItem* item = new PartitionMenuItem(partition->ContentName(),
867 label, menuLabel, new BMessage(SOURCE_PARTITION), partition->ID());
893 TargetVisitor::Visit(BPartition *partition, int32 level)
895 if (partition->ContentSize() < 20 * 1024 * 1024) {
901 if (partition->CountChildren() > 0) {
902 // Looks like an extended partition, or the device itself.
908 // be great to pick the partition which just appeared!
911 if (partition->IsMounted()) {
913 partition->GetMountPoint(&mountPoint);
921 && !partition->IsReadOnly()
922 && partition->ContentType() != NULL
923 && strcmp(partition->ContentType(), kPartitionTypeBFS) == 0;
927 make_partition_label(partition, label, menuLabel, !isValidTarget);
928 PartitionMenuItem* item = new PartitionMenuItem(partition->ContentName(),
929 label, menuLabel, new BMessage(TARGET_PARTITION), partition->ID());