From db227595579a4f8e29757dcb8da33f423ed6e0cb Mon Sep 17 00:00:00 2001 From: "ben%netscape.com" Date: Mon, 29 Apr 2002 10:27:55 +0000 Subject: [PATCH] History DataSource --- camino/CHHistoryDataSource.h | 17 +++++++++++++ camino/CHHistoryDataSource.mm | 32 ++++++++++++++++++++++++ camino/src/history/HistoryDataSource.h | 17 +++++++++++++ camino/src/history/HistoryDataSource.mm | 32 ++++++++++++++++++++++++ chimera/CHHistoryDataSource.h | 17 +++++++++++++ chimera/CHHistoryDataSource.mm | 32 ++++++++++++++++++++++++ chimera/src/history/HistoryDataSource.h | 17 +++++++++++++ chimera/src/history/HistoryDataSource.mm | 32 ++++++++++++++++++++++++ 8 files changed, 196 insertions(+) create mode 100644 camino/CHHistoryDataSource.h create mode 100644 camino/CHHistoryDataSource.mm create mode 100644 camino/src/history/HistoryDataSource.h create mode 100644 camino/src/history/HistoryDataSource.mm create mode 100644 chimera/CHHistoryDataSource.h create mode 100644 chimera/CHHistoryDataSource.mm create mode 100644 chimera/src/history/HistoryDataSource.h create mode 100644 chimera/src/history/HistoryDataSource.mm diff --git a/camino/CHHistoryDataSource.h b/camino/CHHistoryDataSource.h new file mode 100644 index 00000000000..eb883d8340a --- /dev/null +++ b/camino/CHHistoryDataSource.h @@ -0,0 +1,17 @@ +// +// CHHistoryDataSource.h +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import + +#import "CHRDFOutlineViewDataSource.h" + +@interface CHHistoryDataSource : CHRDFOutlineViewDataSource { + +} + +@end diff --git a/camino/CHHistoryDataSource.mm b/camino/CHHistoryDataSource.mm new file mode 100644 index 00000000000..2edda3125a4 --- /dev/null +++ b/camino/CHHistoryDataSource.mm @@ -0,0 +1,32 @@ +// +// CHHistoryDataSource.mm +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import "CHHistoryDataSource.h" + +#include "nsIRDFService.h" +#include "nsIRDFDataSource.h" +#include "nsIRDFResource.h" + +#include "nsComponentManagerUtils.h" + +@implementation CHHistoryDataSource + +- (void) ensureDataSourceLoaded +{ + [super ensureDataSourceLoaded]; + + // Get the Global History DataSource + mRDFService->GetDataSource("rdf:history", &mDataSource); + // Get the Date Folder Root + mRDFService->GetResource("NC:HistoryByDate", &mRootResource); + + [mOutlineView setTarget: self]; + [mOutlineView reloadData]; +} + +@end diff --git a/camino/src/history/HistoryDataSource.h b/camino/src/history/HistoryDataSource.h new file mode 100644 index 00000000000..eb883d8340a --- /dev/null +++ b/camino/src/history/HistoryDataSource.h @@ -0,0 +1,17 @@ +// +// CHHistoryDataSource.h +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import + +#import "CHRDFOutlineViewDataSource.h" + +@interface CHHistoryDataSource : CHRDFOutlineViewDataSource { + +} + +@end diff --git a/camino/src/history/HistoryDataSource.mm b/camino/src/history/HistoryDataSource.mm new file mode 100644 index 00000000000..2edda3125a4 --- /dev/null +++ b/camino/src/history/HistoryDataSource.mm @@ -0,0 +1,32 @@ +// +// CHHistoryDataSource.mm +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import "CHHistoryDataSource.h" + +#include "nsIRDFService.h" +#include "nsIRDFDataSource.h" +#include "nsIRDFResource.h" + +#include "nsComponentManagerUtils.h" + +@implementation CHHistoryDataSource + +- (void) ensureDataSourceLoaded +{ + [super ensureDataSourceLoaded]; + + // Get the Global History DataSource + mRDFService->GetDataSource("rdf:history", &mDataSource); + // Get the Date Folder Root + mRDFService->GetResource("NC:HistoryByDate", &mRootResource); + + [mOutlineView setTarget: self]; + [mOutlineView reloadData]; +} + +@end diff --git a/chimera/CHHistoryDataSource.h b/chimera/CHHistoryDataSource.h new file mode 100644 index 00000000000..eb883d8340a --- /dev/null +++ b/chimera/CHHistoryDataSource.h @@ -0,0 +1,17 @@ +// +// CHHistoryDataSource.h +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import + +#import "CHRDFOutlineViewDataSource.h" + +@interface CHHistoryDataSource : CHRDFOutlineViewDataSource { + +} + +@end diff --git a/chimera/CHHistoryDataSource.mm b/chimera/CHHistoryDataSource.mm new file mode 100644 index 00000000000..2edda3125a4 --- /dev/null +++ b/chimera/CHHistoryDataSource.mm @@ -0,0 +1,32 @@ +// +// CHHistoryDataSource.mm +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import "CHHistoryDataSource.h" + +#include "nsIRDFService.h" +#include "nsIRDFDataSource.h" +#include "nsIRDFResource.h" + +#include "nsComponentManagerUtils.h" + +@implementation CHHistoryDataSource + +- (void) ensureDataSourceLoaded +{ + [super ensureDataSourceLoaded]; + + // Get the Global History DataSource + mRDFService->GetDataSource("rdf:history", &mDataSource); + // Get the Date Folder Root + mRDFService->GetResource("NC:HistoryByDate", &mRootResource); + + [mOutlineView setTarget: self]; + [mOutlineView reloadData]; +} + +@end diff --git a/chimera/src/history/HistoryDataSource.h b/chimera/src/history/HistoryDataSource.h new file mode 100644 index 00000000000..eb883d8340a --- /dev/null +++ b/chimera/src/history/HistoryDataSource.h @@ -0,0 +1,17 @@ +// +// CHHistoryDataSource.h +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import + +#import "CHRDFOutlineViewDataSource.h" + +@interface CHHistoryDataSource : CHRDFOutlineViewDataSource { + +} + +@end diff --git a/chimera/src/history/HistoryDataSource.mm b/chimera/src/history/HistoryDataSource.mm new file mode 100644 index 00000000000..2edda3125a4 --- /dev/null +++ b/chimera/src/history/HistoryDataSource.mm @@ -0,0 +1,32 @@ +// +// CHHistoryDataSource.mm +// Chimera +// +// Created by Ben Goodger on Sun Apr 28 2002. +// Copyright (c) 2001 __MyCompanyName__. All rights reserved. +// + +#import "CHHistoryDataSource.h" + +#include "nsIRDFService.h" +#include "nsIRDFDataSource.h" +#include "nsIRDFResource.h" + +#include "nsComponentManagerUtils.h" + +@implementation CHHistoryDataSource + +- (void) ensureDataSourceLoaded +{ + [super ensureDataSourceLoaded]; + + // Get the Global History DataSource + mRDFService->GetDataSource("rdf:history", &mDataSource); + // Get the Date Folder Root + mRDFService->GetResource("NC:HistoryByDate", &mRootResource); + + [mOutlineView setTarget: self]; + [mOutlineView reloadData]; +} + +@end