Bug 120916 PostScript/Xprint module revamp

BeOS const fix for Bewildered tinderbox
This commit is contained in:
timeless%mac.com 2002-02-12 22:18:00 +00:00
Родитель 4495f7de53
Коммит 6bc2521083
2 изменённых файлов: 15 добавлений и 9 удалений

Просмотреть файл

@ -219,6 +219,8 @@ NS_IMETHODIMP nsDeviceContextSpecBeOS::Init(nsIPrintSettings* aPS, PRBool aQuiet
{
nsresult rv = NS_ERROR_FAILURE;
NS_ASSERTION(nsnull != aPS, "No print settings.");
mPrintSettings = aPS;
// if there is a current selection then enable the "Selection" radio button
if (aPS != nsnull) {
@ -358,7 +360,7 @@ NS_IMETHODIMP nsDeviceContextSpecBeOS :: GetToPrinter( PRBool &aToPrinter )
return NS_OK;
}
NS_IMETHODIMP nsDeviceContextSpecBeOS::GetPrinterName ( char **aPrinter )
NS_IMETHODIMP nsDeviceContextSpecBeOS::GetPrinterName ( const char **aPrinter )
{
*aPrinter = &mPrData.printer[0];
return NS_OK;
@ -449,13 +451,13 @@ NS_IMETHODIMP nsDeviceContextSpecBeOS :: GetLeftMargin ( float &value )
return NS_OK;
}
NS_IMETHODIMP nsDeviceContextSpecBeOS :: GetCommand ( char **aCommand )
NS_IMETHODIMP nsDeviceContextSpecBeOS::GetCommand ( const char **aCommand )
{
*aCommand = &mPrData.command[0];
return NS_OK;
}
NS_IMETHODIMP nsDeviceContextSpecBeOS :: GetPath ( char **aPath )
NS_IMETHODIMP nsDeviceContextSpecBeOS::GetPath ( const char **aPath )
{
*aPath = &mPrData.path[0];
return NS_OK;
@ -476,8 +478,10 @@ NS_IMETHODIMP nsDeviceContextSpecBeOS :: ClosePrintManager()
return NS_OK;
}
NS_IMETHODIMP nsDeviceContextSpecBeOS::GetPageSizeInTwips(PRInt32 *aWidth, PRInt32 *aHeight)
{
return mPrintSettings->GetPageSizeInTwips(aWidth, aHeight);
}
// Printer Enumerator
nsPrinterEnumeratorBeOS::nsPrinterEnumeratorBeOS()

Просмотреть файл

@ -80,10 +80,12 @@ public:
* @return error status
*/
NS_IMETHOD ClosePrintManager();
NS_IMETHOD GetPageSizeInTwips(PRInt32 *aWidth, PRInt32 *aHeight);
NS_IMETHOD GetToPrinter( PRBool &aToPrinter );
NS_IMETHOD GetPrinterName ( char **aPrinter );
NS_IMETHOD GetPrinterName ( const char **aPrinter );
NS_IMETHOD GetCopies ( int &aCopies );
@ -101,9 +103,9 @@ public:
NS_IMETHOD GetRightMargin ( float &value );
NS_IMETHOD GetCommand ( char **aCommand );
NS_IMETHOD GetCommand ( const char **aCommand );
NS_IMETHOD GetPath ( char **aPath );
NS_IMETHOD GetPath ( const char **aPath );
NS_IMETHOD GetPageDimensions (float &aWidth, float &aHeight );
@ -124,7 +126,7 @@ public:
protected:
BeOSPrData mPrData;
nsCOMPtr<nsIPrintSettings> mPrintSettings;
};
//-------------------------------------------------------------------------