mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 01:24:38 +00:00
Replaced array of disk entries in partition list by doubley-linked list of disk entries.
Disabled create, delete and format partition until bugs are fixed. svn path=/trunk/; revision=5382
This commit is contained in:
parent
3ff6d5b32d
commit
0c6dca9836
4 changed files with 1022 additions and 985 deletions
File diff suppressed because it is too large
Load diff
|
@ -16,7 +16,7 @@
|
|||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
/* $Id: partlist.h,v 1.10 2003/04/28 19:44:13 chorns Exp $
|
||||
/* $Id: partlist.h,v 1.11 2003/08/02 16:49:36 ekohl Exp $
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS text-mode setup
|
||||
* FILE: subsys/system/usetup/partlist.h
|
||||
|
@ -66,8 +66,11 @@ typedef struct _PARTENTRY
|
|||
BOOLEAN HidePartEntry;
|
||||
} PARTENTRY, *PPARTENTRY;
|
||||
|
||||
|
||||
typedef struct _DISKENTRY
|
||||
{
|
||||
LIST_ENTRY ListEntry;
|
||||
|
||||
ULONGLONG DiskSize;
|
||||
ULONGLONG Cylinders;
|
||||
ULONGLONG TracksPerCylinder;
|
||||
|
@ -77,7 +80,6 @@ typedef struct _DISKENTRY
|
|||
USHORT Port;
|
||||
USHORT Bus;
|
||||
USHORT Id;
|
||||
BOOL FixedDisk;
|
||||
|
||||
UNICODE_STRING DriverName;
|
||||
|
||||
|
@ -99,11 +101,10 @@ typedef struct _PARTLIST
|
|||
ULONG TopDisk;
|
||||
ULONG TopPartition;
|
||||
|
||||
ULONG CurrentDisk;
|
||||
PDISKENTRY CurrentDisk;
|
||||
ULONG CurrentPartition;
|
||||
|
||||
ULONG DiskCount;
|
||||
PDISKENTRY DiskArray;
|
||||
LIST_ENTRY DiskList;
|
||||
|
||||
} PARTLIST, *PPARTLIST;
|
||||
|
||||
|
@ -133,20 +134,20 @@ ScrollDownPartitionList(PPARTLIST List);
|
|||
VOID
|
||||
ScrollUpPartitionList(PPARTLIST List);
|
||||
|
||||
BOOL
|
||||
BOOLEAN
|
||||
GetSelectedPartition(PPARTLIST List,
|
||||
PPARTDATA Data);
|
||||
|
||||
BOOL
|
||||
BOOLEAN
|
||||
GetActiveBootPartition(PPARTLIST List,
|
||||
PPARTDATA Data);
|
||||
|
||||
BOOL
|
||||
BOOLEAN
|
||||
CreateSelectedPartition(PPARTLIST List,
|
||||
ULONG PartType,
|
||||
ULONGLONG NewPartSize);
|
||||
|
||||
BOOL
|
||||
BOOLEAN
|
||||
DeleteSelectedPartition(PPARTLIST List);
|
||||
|
||||
#endif /* __PARTLIST_H__ */
|
||||
|
|
|
@ -810,6 +810,7 @@ SelectPartitionPage(PINPUT_RECORD Ir)
|
|||
return(SELECT_PARTITION_PAGE);
|
||||
}
|
||||
}
|
||||
#if 0
|
||||
else if (Ir->Event.KeyEvent.wVirtualKeyCode == VK_C) /* C */
|
||||
{
|
||||
/* Don't destroy the parition list here */;
|
||||
|
@ -823,6 +824,7 @@ SelectPartitionPage(PINPUT_RECORD Ir)
|
|||
}
|
||||
return(SELECT_PARTITION_PAGE);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* FIXME: Update status text */
|
||||
|
||||
|
@ -1016,6 +1018,7 @@ ShowPartitionSizeInputBox(ULONG MaxSize,
|
|||
}
|
||||
|
||||
|
||||
#if 0
|
||||
static PAGE_NUMBER
|
||||
CreatePartitionPage(PINPUT_RECORD Ir)
|
||||
{
|
||||
|
@ -1076,7 +1079,7 @@ CreatePartitionPage(PINPUT_RECORD Ir)
|
|||
continue;
|
||||
}
|
||||
|
||||
assert(PartEntry->Unpartitioned == TRUE);
|
||||
// assert(PartEntry->Unpartitioned == TRUE);
|
||||
PartEntry->PartType = PARTITION_ENTRY_UNUSED;
|
||||
PartEntry->Used = TRUE;
|
||||
|
||||
|
@ -1130,6 +1133,7 @@ CreatePartitionPage(PINPUT_RECORD Ir)
|
|||
|
||||
return(SELECT_PARTITION_PAGE);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
static PFILE_SYSTEM_LIST
|
||||
|
@ -2032,6 +2036,7 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
|||
|
||||
SetStatusText(" Please wait...");
|
||||
|
||||
#if 0
|
||||
if (ActivePartitionValid == FALSE)
|
||||
{
|
||||
/* Mark the chosen partition as active since there is no active
|
||||
|
@ -2092,6 +2097,7 @@ BootLoaderPage(PINPUT_RECORD Ir)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (ActivePartition.PartType == PARTITION_ENTRY_UNUSED)
|
||||
{
|
||||
|
@ -2812,9 +2818,11 @@ NtProcessStartup(PPEB Peb)
|
|||
Page = SelectPartitionPage(&Ir);
|
||||
break;
|
||||
|
||||
#if 0
|
||||
case CREATE_PARTITION_PAGE:
|
||||
Page = CreatePartitionPage(&Ir);
|
||||
break;
|
||||
#endif
|
||||
|
||||
case SELECT_FILE_SYSTEM_PAGE:
|
||||
Page = SelectFileSystemPage(&Ir);
|
||||
|
|
|
@ -27,6 +27,11 @@
|
|||
#ifndef __USETUP_H__
|
||||
#define __USETUP_H__
|
||||
|
||||
#ifdef assert
|
||||
#undef assert
|
||||
#endif
|
||||
#define assert(x)
|
||||
|
||||
#define DPRINT1(args...) do { DbgPrint("(%s:%d) ",__FILE__,__LINE__); DbgPrint(args); } while(0);
|
||||
#define CHECKPOINT1 do { DbgPrint("%s:%d\n",__FILE__,__LINE__); } while(0);
|
||||
|
||||
|
|
Loading…
Reference in a new issue