File: SampleShell.h

package info (click to toggle)
gmod 3.1-8.3
  • links: PTS
  • area: main
  • in suites: woody
  • size: 1,340 kB
  • ctags: 808
  • sloc: cpp: 7,764; makefile: 76
file content (73 lines) | stat: -rw-r--r-- 1,006 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
// -*-C++-*-
// This file is part of the gmod package
// Copyright (C) 1997 by Andrew J. Robinson

#ifndef __SampleShellH
#define __SampleShellH

#include "defines.h"
#include "structs.h"
#include "Sample.h"

#ifdef USE_X

#include <qapp.h>
#include <qlistbox.h>
#include <qpushbt.h>

#endif

#ifndef USE_NCURSES

class SampleShell : public QWidget
{
  Q_OBJECT

public:
  SampleShell(QWidget *w = 0);
  void setSamples(Sample **, int);
  
 public slots:
 void showSampleShell();

protected:
  void resizeEvent(QResizeEvent *);

private:
  QListBox *sampleList;
  QPushButton *closeButton;

 private slots:
 void closeSampleShell();
};
#endif

#ifndef USE_X

class SampleShell
{
public:
#ifdef USE_NCURSES
  SampleShell(int);
  void scrollSamples(int);
#else
  SampleShell(int, int);
#endif
  void setSamples(Sample **, int);

private:
  int background_;

#ifdef USE_NCURSES
  int firstVisible_;
  int nrSamples_;
  int sampleLines_;
  WINDOW *sampleWin_;
#else
  int showEmpty_;
#endif
};

#endif

#endif