1274116Sdteske/*-
2295107Sdteske * Copyright (c) 2013-2016 Devin Teske <dteske@FreeBSD.org>
3274116Sdteske * All rights reserved.
4274116Sdteske *
5274116Sdteske * Redistribution and use in source and binary forms, with or without
6274116Sdteske * modification, are permitted provided that the following conditions
7274116Sdteske * are met:
8274116Sdteske * 1. Redistributions of source code must retain the above copyright
9274116Sdteske *    notice, this list of conditions and the following disclaimer.
10274116Sdteske * 2. Redistributions in binary form must reproduce the above copyright
11274116Sdteske *    notice, this list of conditions and the following disclaimer in the
12274116Sdteske *    documentation and/or other materials provided with the distribution.
13274116Sdteske *
14274116Sdteske * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15274116Sdteske * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16274116Sdteske * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17274116Sdteske * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18274116Sdteske * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19274116Sdteske * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20274116Sdteske * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21274116Sdteske * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22274116Sdteske * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23274116Sdteske * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24274116Sdteske * SUCH DAMAGE.
25274116Sdteske *
26274116Sdteske * $FreeBSD: releng/10.3/lib/libdpv/dpv_private.h 295107 2016-02-01 00:44:29Z dteske $
27274116Sdteske */
28274116Sdteske
29274116Sdteske#ifndef _DPV_PRIVATE_H_
30274116Sdteske#define _DPV_PRIVATE_H_
31274116Sdteske
32274116Sdteske#include <sys/types.h>
33274116Sdteske
34274116Sdteske/* Debugging */
35274116Sdteskeextern uint8_t debug;
36274116Sdteske
37274116Sdteske/* Data to process */
38274116Sdteskeextern unsigned int dpv_nfiles;
39274116Sdteske
40274116Sdteske/* Extra display information */
41295107Sdteskeextern uint8_t keep_tite;
42274116Sdteskeextern uint8_t no_labels;
43274116Sdteskeextern uint8_t wide;
44274116Sdteskeextern char *msg_done, *msg_fail, *msg_pending;
45274116Sdteskeextern char *pprompt, *aprompt;
46274116Sdteskeextern const char status_format[];
47274116Sdteske
48274116Sdteske/* Defaults */
49274116Sdteske#define DIALOG_UPDATES_PER_SEC	16
50274116Sdteske#define XDIALOG_UPDATES_PER_SEC	4
51274116Sdteske#define DISPLAY_LIMIT_DEFAULT	0	/* Auto-calculate */
52274116Sdteske#define LABEL_SIZE_DEFAULT	28
53274116Sdteske#define PBAR_SIZE_DEFAULT	17
54274116Sdteske#define STATUS_UPDATES_PER_SEC	2
55274116Sdteske
56274116Sdteske/* states for dprompt_add_files() of dprompt.c */
57274116Sdteskeenum dprompt_state {
58274116Sdteske	DPROMPT_NONE = 0,	/* Default */
59274116Sdteske	DPROMPT_PENDING,	/* Pending */
60274116Sdteske	DPROMPT_PBAR,		/* Progress bar */
61274116Sdteske	DPROMPT_END_STATE,	/* Done/Fail */
62274116Sdteske	DPROMPT_DETAILS,	/* dpv_file_node->read */
63274116Sdteske	DPROMPT_CUSTOM_MSG,	/* dpv_file_node->msg */
64274116Sdteske	DPROMPT_MINIMAL,	/* whitespace */
65274116Sdteske};
66274116Sdteske
67274116Sdteske#endif /* !_DPV_PRIVATE_H_ */
68