NCBI C++ ToolKit
Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
CAuthorNamesPanel Class Reference

Search Toolkit Book for CAuthorNamesPanel

#include <gui/widgets/edit/authornames_panel.hpp>

+ Inheritance diagram for CAuthorNamesPanel:
+ Collaboration diagram for CAuthorNamesPanel:

Public Types

enum  {
  ID_AUTHORNAMES = 10022 , ID_ADDAUTH = 10023 , ID_ADDCONSORTIUM = 10024 , ID_IMPORT_AUTHORS = 10025 ,
  ID_IMPORT_AUTHORS_AFFILIATION = 10026 , ID_PANEL = 10027
}
 Control identifiers. More...
 

Public Member Functions

 CAuthorNamesPanel ()
 Constructors. More...
 
 CAuthorNamesPanel (wxWindow *parent, CSerialObject &object, bool show_replace_buttons, wxWindowID id=ID_AUTHORNAMES, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(400, 300), long style=wxTAB_TRAVERSAL)
 
bool Create (wxWindow *parent, wxWindowID id=ID_AUTHORNAMES, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(400, 300), long style=wxTAB_TRAVERSAL)
 Creation. More...
 
 ~CAuthorNamesPanel ()
 Destructor. More...
 
void Init ()
 Initialises member variables. More...
 
void CreateControls ()
 Creates the controls and sizers. More...
 
virtual bool TransferDataToWindow ()
 
virtual bool TransferDataFromWindow ()
 
bool x_GetAuthors (bool keep_blank=false)
 
void PopulateAuthors (objects::CAuth_list &auth_list)
 
void OnAddauthHyperlinkClicked (wxHyperlinkEvent &event)
 wxEVT_COMMAND_HYPERLINK event handler for ID_ADDAUTH More...
 
void OnAddconsortiumHyperlinkClicked (wxHyperlinkEvent &event)
 wxEVT_COMMAND_HYPERLINK event handler for ID_ADDCONSORTIUM More...
 
void OnImportAuthorsHyperlinkClicked (wxHyperlinkEvent &event)
 wxEVT_COMMAND_HYPERLINK event handler for ID_IMPORT_AUTHORS More...
 
void OnImportAuthorsAffiliationHyperlinkClicked (wxHyperlinkEvent &event)
 wxEVT_COMMAND_HYPERLINK event handler for ID_IMPORT_AUTHORS_AFFILIATION More...
 
void OnDelete (wxHyperlinkEvent &event)
 
void OnReplaceAllAuthors (wxCommandEvent &event)
 
void OnReplaceSameAuthors (wxCommandEvent &event)
 
wxBitmap GetBitmapResource (const wxString &name)
 Retrieves bitmap resources. More...
 
wxIcon GetIconResource (const wxString &name)
 Retrieves icon resources. More...
 
virtual bool IsImportEnabled (void)
 
virtual bool IsExportEnabled (void)
 
virtual CRef< CSerialObjectOnExport (void)
 
virtual void OnImport (CNcbiIfstream &istr)
 
virtual void ApplySubmitBlock (objects::CSubmit_block &block)
 
virtual void ApplyCommand ()
 
virtual wxString GetAnchor ()
 
virtual wxString GetName () const
 
- Public Member Functions inherited from CAuthorNamesContainer
 ~CAuthorNamesContainer ()
 
void DeleteRow (wxWindow *wnd)
 
void ShiftAuthorUp (wxWindow *link)
 
void ShiftAuthorDown (wxWindow *link)
 
void ImportAuthorsFromFile ()
 
virtual void SetWorkDir (const wxString &workDir)
 
- Public Member Functions inherited from IWorkDirClient
virtual ~IWorkDirClient ()
 
- Public Member Functions inherited from ISubmissionPage
virtual ~ISubmissionPage ()
 
virtual bool StepForward ()
 
virtual bool StepBackward ()
 
virtual bool IsFirstPage () const
 
virtual bool IsLastPage () const
 
virtual void ApplyDescriptor (objects::CSeqdesc &desc)
 
virtual void SetSeqEntryHandle (objects::CSeq_entry_Handle seh)
 
CSubmissionPageChangeListenerGetParentWizard (wxWindow *wnd) const
 
virtual void ReportMissingFields (string &text)
 

Static Public Member Functions

static bool ShowToolTips ()
 Should we show tooltips? More...
 
static bool IsAuthorEmpty (const objects::CAuthor &auth)
 

Private Member Functions

void x_AddNewEmptyAuthor (void)
 
void x_SetAffiliation ()
 
ICommandProccessorGetUndoManager ()
 
objects::CSeq_entry_Handle GetSeqEntryHandle ()
 
void x_AdjustScroll (wxWindow *row, bool scroll_to_end=true)
 

Private Attributes

CSerialObjectm_Object
 
CRef< CSerialObjectm_EditedAuthList
 
int m_RowHeight
 
bool m_show_replace_buttons
 
wxWindow * m_Consortium
 
CRef< objects::CSubmit_block > m_SubmitBlock
 

CAuthorNamesContainer implementation

virtual void AddLastAuthor (wxWindow *link)
 
virtual void InsertAuthorBefore (wxWindow *link)
 
virtual void InsertAuthorAfter (wxWindow *link)
 
virtual void SetAuthors (const objects::CAuth_list &auth_list)
 
virtual wxSizerItem * x_FindSingleAuthor (wxWindow *wnd, wxSizerItemList &itemList)
 
virtual void x_AddRowToWindow (wxWindow *row)
 
virtual void x_InsertRowtoWindow (wxWindow *row, size_t index)
 
virtual void x_MoveRowUp (int row_num)
 
virtual int x_FindRow (wxWindow *wnd, wxSizerItemList &itemList)
 

Additional Inherited Members

- Protected Member Functions inherited from CAuthorNamesContainer
 CAuthorNamesContainer ()
 
- Protected Member Functions inherited from ISubmissionPage
bool x_DoStepForward (wxListbook *book)
 
bool x_DoStepBackward (wxListbook *book)
 
- Protected Attributes inherited from CAuthorNamesContainer
wxScrolledWindow * m_ScrolledWindow
 
wxFlexGridSizer * m_Sizer
 
wxString m_WorkDir
 

Detailed Description

CAuthorNamesPanel class declaration

Definition at line 95 of file authornames_panel.hpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Control identifiers.

Enumerator
ID_AUTHORNAMES 
ID_ADDAUTH 
ID_ADDCONSORTIUM 
ID_IMPORT_AUTHORS 
ID_IMPORT_AUTHORS_AFFILIATION 
ID_PANEL 

Definition at line 179 of file authornames_panel.hpp.

Constructor & Destructor Documentation

◆ CAuthorNamesPanel() [1/2]

CAuthorNamesPanel::CAuthorNamesPanel ( )

Constructors.

Definition at line 114 of file authornames_panel.cpp.

References Init().

◆ CAuthorNamesPanel() [2/2]

CAuthorNamesPanel::CAuthorNamesPanel ( wxWindow *  parent,
CSerialObject object,
bool  show_replace_buttons,
wxWindowID  id = ID_AUTHORNAMES,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxSize(400, 300),
long  style = wxTAB_TRAVERSAL 
)

◆ ~CAuthorNamesPanel()

CAuthorNamesPanel::~CAuthorNamesPanel ( )

Destructor.

Definition at line 159 of file authornames_panel.cpp.

Member Function Documentation

◆ AddLastAuthor()

void CAuthorNamesPanel::AddLastAuthor ( wxWindow *  link)
virtual

◆ ApplyCommand()

void CAuthorNamesPanel::ApplyCommand ( )
virtual

◆ ApplySubmitBlock()

void CAuthorNamesPanel::ApplySubmitBlock ( objects::CSubmit_block &  block)
virtual

Reimplemented from ISubmissionPage.

Definition at line 1110 of file authornames_panel.cpp.

References m_SubmitBlock, CRef< C, Locker >::Reset(), and SetAuthors().

Referenced by CReferencePanel::ApplySubmitBlock().

◆ Create()

bool CAuthorNamesPanel::Create ( wxWindow *  parent,
wxWindowID  id = ID_AUTHORNAMES,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxSize(400, 300),
long  style = wxTAB_TRAVERSAL 
)

Creation.

Definition at line 138 of file authornames_panel.cpp.

References CreateControls(), and ncbi::grid::netcache::search::fields::size.

Referenced by CAuthorNamesPanel().

◆ CreateControls()

void CAuthorNamesPanel::CreateControls ( )

◆ GetAnchor()

virtual wxString CAuthorNamesPanel::GetAnchor ( void  )
inlinevirtual

Reimplemented from ISubmissionPage.

Definition at line 193 of file authornames_panel.hpp.

References _.

◆ GetBitmapResource()

wxBitmap CAuthorNamesPanel::GetBitmapResource ( const wxString &  name)

Retrieves bitmap resources.

Definition at line 700 of file authornames_panel.cpp.

◆ GetIconResource()

wxIcon CAuthorNamesPanel::GetIconResource ( const wxString &  name)

Retrieves icon resources.

Definition at line 713 of file authornames_panel.cpp.

◆ GetName()

virtual wxString CAuthorNamesPanel::GetName ( void  ) const
inlinevirtual

Reimplemented from ISubmissionPage.

Definition at line 194 of file authornames_panel.hpp.

References SYMBOL_CAUTHORNAMESPANEL_TITLE.

◆ GetSeqEntryHandle()

CSeq_entry_Handle CAuthorNamesPanel::GetSeqEntryHandle ( void  )
private

◆ GetUndoManager()

ICommandProccessor * CAuthorNamesPanel::GetUndoManager ( )
private

◆ Init()

void CAuthorNamesPanel::Init ( void  )

Initialises member variables.

Definition at line 170 of file authornames_panel.cpp.

References CAuthorNamesContainer::m_ScrolledWindow, CAuthorNamesContainer::m_Sizer, and NULL.

Referenced by CAuthorNamesPanel().

◆ InsertAuthorAfter()

void CAuthorNamesPanel::InsertAuthorAfter ( wxWindow *  link)
virtual

◆ InsertAuthorBefore()

void CAuthorNamesPanel::InsertAuthorBefore ( wxWindow *  link)
virtual

◆ IsAuthorEmpty()

bool CAuthorNamesPanel::IsAuthorEmpty ( const objects::CAuthor &  auth)
static

◆ IsExportEnabled()

bool CAuthorNamesPanel::IsExportEnabled ( void  )
virtual

Reimplemented from CImportExportAccess.

Definition at line 836 of file authornames_panel.cpp.

◆ IsImportEnabled()

bool CAuthorNamesPanel::IsImportEnabled ( void  )
virtual

Reimplemented from CImportExportAccess.

Definition at line 831 of file authornames_panel.cpp.

◆ OnAddauthHyperlinkClicked()

void CAuthorNamesPanel::OnAddauthHyperlinkClicked ( wxHyperlinkEvent &  event)

wxEVT_COMMAND_HYPERLINK event handler for ID_ADDAUTH

Definition at line 738 of file authornames_panel.cpp.

References x_AddNewEmptyAuthor().

◆ OnAddconsortiumHyperlinkClicked()

void CAuthorNamesPanel::OnAddconsortiumHyperlinkClicked ( wxHyperlinkEvent &  event)

wxEVT_COMMAND_HYPERLINK event handler for ID_ADDCONSORTIUM

Definition at line 748 of file authornames_panel.cpp.

References CAuthorNamesContainer::m_ScrolledWindow, row, CAuth_list_Base::SetNames(), and x_AddRowToWindow().

◆ OnDelete()

void CAuthorNamesPanel::OnDelete ( wxHyperlinkEvent &  event)

Definition at line 544 of file authornames_panel.cpp.

References CAuthorNamesContainer::DeleteRow(), and wxT.

◆ OnExport()

CRef< CSerialObject > CAuthorNamesPanel::OnExport ( void  )
virtual

Reimplemented from CImportExportAccess.

Definition at line 841 of file authornames_panel.cpp.

References PopulateAuthors().

◆ OnImport()

void CAuthorNamesPanel::OnImport ( CNcbiIfstream istr)
virtual

Reimplemented from CImportExportAccess.

Definition at line 848 of file authornames_panel.cpp.

References MSerial_AsnText, and SetAuthors().

Referenced by OnImportAuthorsAffiliationHyperlinkClicked().

◆ OnImportAuthorsAffiliationHyperlinkClicked()

void CAuthorNamesPanel::OnImportAuthorsAffiliationHyperlinkClicked ( wxHyperlinkEvent &  event)

◆ OnImportAuthorsHyperlinkClicked()

void CAuthorNamesPanel::OnImportAuthorsHyperlinkClicked ( wxHyperlinkEvent &  event)

wxEVT_COMMAND_HYPERLINK event handler for ID_IMPORT_AUTHORS

Definition at line 797 of file authornames_panel.cpp.

References CAuthorNamesContainer::ImportAuthorsFromFile().

◆ OnReplaceAllAuthors()

void CAuthorNamesPanel::OnReplaceAllAuthors ( wxCommandEvent &  event)

◆ OnReplaceSameAuthors()

void CAuthorNamesPanel::OnReplaceSameAuthors ( wxCommandEvent &  event)

◆ PopulateAuthors()

void CAuthorNamesPanel::PopulateAuthors ( objects::CAuth_list &  auth_list)

◆ SetAuthors()

void CAuthorNamesPanel::SetAuthors ( const objects::CAuth_list &  auth_list)
virtual

◆ ShowToolTips()

bool CAuthorNamesPanel::ShowToolTips ( )
static

Should we show tooltips?

Definition at line 691 of file authornames_panel.cpp.

◆ TransferDataFromWindow()

bool CAuthorNamesPanel::TransferDataFromWindow ( )
virtual

◆ TransferDataToWindow()

bool CAuthorNamesPanel::TransferDataToWindow ( )
virtual

◆ x_AddNewEmptyAuthor()

void CAuthorNamesPanel::x_AddNewEmptyAuthor ( void  )
private

◆ x_AddRowToWindow()

void CAuthorNamesPanel::x_AddRowToWindow ( wxWindow *  row)
privatevirtual

◆ x_AdjustScroll()

void CAuthorNamesPanel::x_AdjustScroll ( wxWindow *  row,
bool  scroll_to_end = true 
)
private

◆ x_FindRow()

int CAuthorNamesPanel::x_FindRow ( wxWindow *  wnd,
wxSizerItemList &  itemList 
)
privatevirtual

Implements CAuthorNamesContainer.

Definition at line 448 of file authornames_panel.cpp.

References NULL.

◆ x_FindSingleAuthor()

wxSizerItem * CAuthorNamesPanel::x_FindSingleAuthor ( wxWindow *  wnd,
wxSizerItemList &  itemList 
)
privatevirtual

Implements CAuthorNamesContainer.

Definition at line 471 of file authornames_panel.cpp.

References NULL.

◆ x_GetAuthors()

bool CAuthorNamesPanel::x_GetAuthors ( bool  keep_blank = false)

◆ x_InsertRowtoWindow()

void CAuthorNamesPanel::x_InsertRowtoWindow ( wxWindow *  row,
size_t  index 
)
privatevirtual

◆ x_MoveRowUp()

void CAuthorNamesPanel::x_MoveRowUp ( int  row_num)
privatevirtual

◆ x_SetAffiliation()

void CAuthorNamesPanel::x_SetAffiliation ( )
private

Member Data Documentation

◆ m_Consortium

wxWindow* CAuthorNamesPanel::m_Consortium
private

Definition at line 216 of file authornames_panel.hpp.

◆ m_EditedAuthList

CRef<CSerialObject> CAuthorNamesPanel::m_EditedAuthList
private

Definition at line 212 of file authornames_panel.hpp.

Referenced by CAuthorNamesPanel().

◆ m_Object

CSerialObject* CAuthorNamesPanel::m_Object
private

◆ m_RowHeight

int CAuthorNamesPanel::m_RowHeight
private

Definition at line 213 of file authornames_panel.hpp.

Referenced by TransferDataToWindow(), and x_AdjustScroll().

◆ m_show_replace_buttons

bool CAuthorNamesPanel::m_show_replace_buttons
private

Definition at line 214 of file authornames_panel.hpp.

Referenced by CreateControls().

◆ m_SubmitBlock

CRef<objects::CSubmit_block> CAuthorNamesPanel::m_SubmitBlock
private

Definition at line 217 of file authornames_panel.hpp.

Referenced by ApplyCommand(), and ApplySubmitBlock().


The documentation for this class was generated from the following files:
Modified on Wed Sep 04 15:04:08 2024 by modify_doxy.py rev. 669887