Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes
CNsIClipBoardCmd Class Reference

#include <nsIclipboardcmd.h>

Collaboration diagram for CNsIClipBoardCmd:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 CNsIClipBoardCmd (nsIWebBrowser *mWebBrowser)
 ~CNsIClipBoardCmd ()
void OnStartTests (UINT nMenuID)
void OnPasteTest ()
void OnCopyTest ()
void OnSelectAllTest ()
void OnSelectNoneTest ()
void OnCutSelectionTest ()
void copyLinkLocationTest ()
void canCopySelectionTest ()
void canCutSelectionTest ()
void canPasteTest ()

Public Attributes

nsCOMPtr< nsIWebBrowserqaWebBrowser

Detailed Description

Definition at line 44 of file nsIclipboardcmd.h.


Constructor & Destructor Documentation

Definition at line 49 of file nsIclipboardcmd.cpp.

{
       qaWebBrowser = mWebBrowser;
}

Definition at line 55 of file nsIclipboardcmd.cpp.

{
}

Member Function Documentation

Definition at line 186 of file nsIclipboardcmd.cpp.

{
    PRBool canCopySelection = PR_FALSE;
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
       rv = clipCmds->CanCopySelection(&canCopySelection);
          RvTestResult(rv, "nsIClipboardCommands::CanCopySelection()' rv test", 1);

       if(canCopySelection)
          QAOutput("The selection you made Can be copied", 2);
       else
          QAOutput("Either you did not make a selection or The selection you made Cannot be copied", 2);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 205 of file nsIclipboardcmd.cpp.

{
    PRBool canCutSelection = PR_FALSE;
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
       rv = clipCmds->CanCutSelection(&canCutSelection);
          RvTestResult(rv, "nsIClipboardCommands::CanCutSelection()' rv test", 1);

          if(canCutSelection)
          QAOutput("The selection you made Can be cut", 2);
       else
          QAOutput("Either you did not make a selection or The selection you made Cannot be cut", 2);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 224 of file nsIclipboardcmd.cpp.

{
    PRBool canPaste = PR_FALSE;
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->CanPaste(&canPaste);
           RvTestResult(rv, "nsIClipboardCommands::CanPaste()' rv test", 1);

              if(canPaste)
                     QAOutput("The clipboard contents can be pasted here", 2);
              else
                     QAOutput("The clipboard contents cannot be pasted here", 2);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 172 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing CopyLinkLocation method", 2);
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->CopyLinkLocation();
              RvTestResult(rv, "nsIClipboardCommands::CopyLinkLocation()' rv test", 1);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 116 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing copyselection command");
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->CopySelection();
              RvTestResult(rv, "nsIClipboardCommands::CopySelection()' rv test", 1);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 158 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing cutselection method");
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->CutSelection();
              RvTestResult(rv, "nsIClipboardCommands::CutSelection()' rv test", 1);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 101 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing paste command", 1);
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->Paste();
              RvTestResult(rv, "nsIClipboardCommands::Paste()' rv test", 1);

       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 130 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing selectall method");
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->SelectAll();
              RvTestResult(rv, "nsIClipboardCommands::SelectAll()' rv test", 1);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 144 of file nsIclipboardcmd.cpp.

{
    QAOutput("testing selectnone method");
    nsCOMPtr<nsIClipboardCommands> clipCmds = do_GetInterface(qaWebBrowser);
    if (clipCmds)
       {
        rv = clipCmds->SelectNone();
              RvTestResult(rv, "nsIClipboardCommands::SelectNone()' rv test", 1);
       }
       else
              QAOutput("We didn't get the clipboard object.", 1);
}

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 54 of file nsIclipboardcmd.h.


The documentation for this class was generated from the following files: