installer-framework/examples/doc/modifyextract.qdoc
Leena Miettinen 5a1b61d27e Doc: update docs for Modify Extract Installer example
Fix issues in the example files and unify some values to
make it possible to use standard text for the configuring
section.

Change-Id: I4e4236d519d075fc1f0461e3b863989ca0373cd3
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
2015-01-08 17:02:30 +01:00

70 lines
2.6 KiB
Plaintext

/****************************************************************************
**
** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the Qt Installer Framework.
**
** $QT_BEGIN_LICENSE:FDL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Digia. For licensing terms and
** conditions see http://qt.digia.com/licensing. For further information
** use the contact form at http://qt.digia.com/contact-us.
**
** GNU Free Documentation License Usage
** Alternatively, this file may be used under the terms of the GNU Free
** Documentation License version 1.3 as published by the Free Software
** Foundation and appearing in the file included in the packaging of
** this file. Please review the following information to ensure
** the GNU Free Documentation License version 1.3 requirements
** will be met: http://www.gnu.org/copyleft/fdl.html.
** $QT_END_LICENSE$
**
****************************************************************************/
/*!
\example modifyextract
\ingroup qtifwexamples
\title Modify Extract Installer Example
\brief Using the extract archive hook to modify the target path.
\image qtifw-examples-modifyextract.png
\e{Modify Extract Installer} illustrates how to overwrite the
\c{component.createOperationsForArchive()} function to be able to install a
component to a modified path.
\include installerfw-examples-configuring.qdocinc
\quotefile modifyextract/config/config.xml
\include installerfw-examples-packaging.qdocinc
\list
\li The \c <Default> section is set to \c true to preselect the
component in the installer.
\li The \c <Script> section specifies the file name of the JavaScript
file that is loaded to perform operations.
\endlist
\quotefile modifyextract/packages/org.qtproject.ifw.example.modifyextract/meta/package.xml
\section1 Modifying Target Path
In installscript.js, we overwrite the default
\c{component.createOperationsForArchive()} implementation to be able to
register an \c Extract operation with a custom argument:
\quotefromfile modifyextract/packages/org.qtproject.ifw.example.modifyextract/meta/installscript.js
\skipto createOperationsForArchive
\printuntil {
\skipto component.addOperation
\printuntil }
\include installerfw-examples-generating.qdocinc
*/