dpv_private.h revision 274116
138889Sjdp/*- 2218822Sdim * Copyright (c) 2013-2014 Devin Teske <dteske@FreeBSD.org> 3130561Sobrien * All rights reserved. 438889Sjdp * 538889Sjdp * Redistribution and use in source and binary forms, with or without 685815Sobrien * modification, are permitted provided that the following conditions 738889Sjdp * are met: 885815Sobrien * 1. Redistributions of source code must retain the above copyright 985815Sobrien * notice, this list of conditions and the following disclaimer. 1085815Sobrien * 2. Redistributions in binary form must reproduce the above copyright 1185815Sobrien * notice, this list of conditions and the following disclaimer in the 1238889Sjdp * documentation and/or other materials provided with the distribution. 1385815Sobrien * 1485815Sobrien * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 1585815Sobrien * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1685815Sobrien * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1738889Sjdp * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 1885815Sobrien * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1985815Sobrien * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20218822Sdim * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21218822Sdim * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 2238889Sjdp * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23218822Sdim * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 2438889Sjdp * SUCH DAMAGE. 2538889Sjdp * 2638889Sjdp * $FreeBSD: head/lib/libdpv/dpv_private.h 274116 2014-11-04 23:46:01Z dteske $ 2738889Sjdp */ 2889857Sobrien 2938889Sjdp#ifndef _DPV_PRIVATE_H_ 3038889Sjdp#define _DPV_PRIVATE_H_ 3138889Sjdp 3285815Sobrien#include <sys/types.h> 33130561Sobrien 3438889Sjdp/* Debugging */ 35218822Sdimextern uint8_t debug; 36218822Sdim 37218822Sdim/* Data to process */ 38218822Sdimextern unsigned int dpv_nfiles; 39218822Sdim 40218822Sdim/* Extra display information */ 41218822Sdimextern uint8_t no_labels; 42218822Sdimextern uint8_t wide; 43218822Sdimextern char *msg_done, *msg_fail, *msg_pending; 44218822Sdimextern char *pprompt, *aprompt; 45218822Sdimextern const char status_format[]; 46218822Sdim 47218822Sdim/* Defaults */ 48218822Sdim#define DIALOG_UPDATES_PER_SEC 16 49218822Sdim#define XDIALOG_UPDATES_PER_SEC 4 50218822Sdim#define DISPLAY_LIMIT_DEFAULT 0 /* Auto-calculate */ 51218822Sdim#define LABEL_SIZE_DEFAULT 28 52218822Sdim#define PBAR_SIZE_DEFAULT 17 53218822Sdim#define STATUS_UPDATES_PER_SEC 2 54218822Sdim 55218822Sdim/* states for dprompt_add_files() of dprompt.c */ 56218822Sdimenum dprompt_state { 5738889Sjdp DPROMPT_NONE = 0, /* Default */ 5838889Sjdp DPROMPT_PENDING, /* Pending */ 5938889Sjdp DPROMPT_PBAR, /* Progress bar */ 60218822Sdim DPROMPT_END_STATE, /* Done/Fail */ 61218822Sdim DPROMPT_DETAILS, /* dpv_file_node->read */ 62218822Sdim DPROMPT_CUSTOM_MSG, /* dpv_file_node->msg */ 63218822Sdim DPROMPT_MINIMAL, /* whitespace */ 64218822Sdim}; 65218822Sdim 66218822Sdim#endif /* !_DPV_PRIVATE_H_ */ 67218822Sdim