adding QA_Partner support.

git-svn-id: svn://10.0.0.236/trunk@9872 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
pinkerton%netscape.com 1998-09-11 19:00:41 +00:00
parent a3080e873f
commit aa492b455d
7 changed files with 29 additions and 24 deletions

View File

@ -73,7 +73,7 @@ extern "C"
#include <LGACheckbox.h>
#include <LGARadioButton.h>
//#include <QAP_Assist.h>
#include <QAP_Assist.h>
//#include <ICAPI.h>

View File

@ -28,7 +28,7 @@
#include <LTableSingleSelector.h>
#include <LTableArrayStorage.h>
#include <LDropFlag.h>
//#include <QAP_Assist.h>
#include <QAP_Assist.h>
#include "CPrefsMediator.h"
@ -45,7 +45,7 @@ struct CellData
//----------------------------------------------------------------------------------------
CMenuTable::CMenuTable(LStream *inStream)
: LTextHierTable(inStream)
//, CQAPartnerTableMixin(this)
, CQAPartnerTableMixin(this)
//----------------------------------------------------------------------------------------
{
*inStream >> mLeafTextTraits;
@ -455,6 +455,8 @@ void CMenuTable::ClickSelf(const SMouseDownEvent &inMouseDown)
#pragma mark -
#if defined(QAP_BUILD)
#include <LScrollerView.h>
//-----------------------------------
void CMenuTable::QapGetListInfo(PQAPLISTINFO pInfo)
//-----------------------------------
@ -479,8 +481,11 @@ void CMenuTable::QapGetListInfo(PQAPLISTINFO pInfo)
LScrollerView *myScroller = dynamic_cast<LScrollerView *>(GetSuperView());
if (myScroller != NULL)
{
#if 0
// LScrollerView does not provide public access to the scrollbars (pinkerton)
if (myScroller->GetVScrollbar() != NULL)
macVScroll = myScroller->GetVScrollbar()->GetMacControl();
#endif
}
pInfo->itemCount = (short)outRows;

View File

@ -19,7 +19,7 @@
#pragma once
#include <LTextHierTable.h>
//#include <QAP_Assist.h>
#include <QAP_Assist.h>
//========================================================================================
class CMenuTable
@ -30,7 +30,7 @@ class CMenuTable
//========================================================================================
: public LTextHierTable
, public LBroadcaster
//, public CQAPartnerTableMixin
, public CQAPartnerTableMixin
{
public:
enum
@ -50,10 +50,10 @@ class CMenuTable
virtual void HiliteCellInactively(const STableCell &inCell, Boolean inHilite);
virtual void ClickSelf(const SMouseDownEvent &inMouseDown);
TableIndexT FindMessage( MessageT message );
//#if defined(QAP_BUILD)
// virtual void QapGetListInfo (PQAPLISTINFO pInfo);
// virtual Ptr QapAddCellToBuf(Ptr pBuf, Ptr pLimit, const STableCell& sTblCell);
//#endif
#if defined(QAP_BUILD)
virtual void QapGetListInfo (PQAPLISTINFO pInfo);
virtual Ptr QapAddCellToBuf(Ptr pBuf, Ptr pLimit, const STableCell& sTblCell);
#endif
protected:
ResIDT mMenuID;

View File

@ -21,8 +21,6 @@
//
// It should be used everywhere in place of LTextColumn.
#if 0 //¥¥¥ don't activate QAP in Mozilla yet
#ifdef PowerPlant_PCH
#include PowerPlant_PCH
#endif
@ -56,6 +54,8 @@ CTextColumn::~CTextColumn()
#pragma mark -
#if defined(QAP_BUILD)
#include <LScrollerView.h>
//-----------------------------------
void CTextColumn::QapGetListInfo(PQAPLISTINFO pInfo)
//-----------------------------------
@ -69,11 +69,14 @@ void CTextColumn::QapGetListInfo(PQAPLISTINFO pInfo)
// fetch vertical scrollbar Macintosh control
ControlHandle macVScroll = NULL;
LScroller *myScroller = dynamic_cast<LScroller *>(GetSuperView());
LScrollerView *myScroller = dynamic_cast<LScrollerView *>(GetSuperView());
if (myScroller != NULL)
{
#if 0
// LScrollerView does not provide public access to its scrollbars (pinkerton)
if (myScroller->GetVScrollbar() != NULL)
macVScroll = myScroller->GetVScrollbar()->GetMacControl();
#endif
}
pInfo->itemCount = (short)outRows;
@ -120,5 +123,3 @@ Ptr CTextColumn::QapAddCellToBuf(Ptr pBuf, Ptr pLimit, const STableCell& sTblCel
}
#endif //QAP_BUILD
#endif //0 //¥¥¥ don't activate QAP in Mozilla yet

View File

@ -27,9 +27,7 @@
#include <LTextColumn.h>
#if 0 //¥¥¥ don't activate QAP in Mozilla yet
#include <QAP_Assist.h>
#include "QAP_Assist.h"
class CTextColumn : public LTextColumn, public CQAPartnerTableMixin
{
@ -50,8 +48,5 @@ public:
#endif //QAP_BUILD
};
#else //0
#define CTextColumn LTextColumn
#endif //0 //¥¥¥ don't activate QAP in Mozilla yet
#endif //CTextColumn_H

View File

@ -298,7 +298,7 @@ CStandardFlexTable::CStandardFlexTable(LStream *inStream)
, LDragAndDrop(GetMacPort(), this)
, LCommander()
, LBroadcaster()
//, CQAPartnerTableMixin(this)
, CQAPartnerTableMixin(this)
, mTableHeaderListener(this)
, mTableHeader(NULL)
, mSelectionList(NULL)
@ -2643,6 +2643,7 @@ CStandardFlexTable :: RowIsContainer( const TableIndexT & inRow, Boolean* outIsE
#pragma mark -
#if defined(QAP_BUILD)
#include <LScrollerView.h>
//----------------------------------------------------------------------------------------
void CStandardFlexTable::QapGetListInfo(PQAPLISTINFO pInfo)
@ -2666,13 +2667,16 @@ void CStandardFlexTable::QapGetListInfo(PQAPLISTINFO pInfo)
LScrollerView *myScroller = dynamic_cast<LScrollerView *>(GetSuperView());
if (myScroller != NULL)
{
#if 0
// there is no public access to the scrollbars in PowerPlant's LScrollerView (pinkerton)
if (myScroller->GetVScrollbar() != NULL)
macVScroll = myScroller->GetVScrollbar()->GetMacControl();
#endif
}
pInfo->itemCount = (short)outRows;
pInfo->topIndex = topLeftCell.row - 1; // must start at 0 even though in QAP-script, Select("#1") selects the first line
pInfo->topOffset = 0;
// pInfo->topOffset = 0;
pInfo->itemHeight = GetRowHeight(0);
pInfo->visibleCount = botRightCell.row - topLeftCell.row + 1;
pInfo->vScroll = macVScroll;

View File

@ -29,7 +29,7 @@
#include <LCommander.h>
#include <LListener.h>
//#include <QAP_Assist.h>
#include <QAP_Assist.h>
#include "NetscapeDragFlavors.h"
#include "LTableViewHeader.h"
@ -72,7 +72,7 @@ class CStandardFlexTable
, public LCommander
, public LBroadcaster
, public CKeyUpReceiver
//, public CQAPartnerTableMixin
, public CQAPartnerTableMixin
{
private:
typedef CSpecialTableView Inherited;