PageRecord record = pages.get(selected);
if( record == null ){
// record has not been created yet
IPageBookViewPage page = selected.createPage();
if( page == null ){
MessagePage messagePage = new MessagePage();
record = new PageRecord( this, messagePage);
messagePage.init( record.getSite() );
messagePage.createControl( pagebook );
messagePage.setMessage( selected.getName() );
}
else {
record = new PageRecord( this, page );
try {
page.init( record.getSite() );