summaryrefslogtreecommitdiffhomepage
path: root/frameworks/libX11.fwrk/src/X11ConnMgr.cpp
blob: 61752f12359aaf0b6b953593afa4f688d8b7d862 (plain)
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
// SPDX-License-Identifier: Apache-2.0
// Copyright 2026, Amlal El Mahrouss (amlal@nekernel.org)
// Licensed under the Apache License, Version 2.0 (see LICENSE file)
// Official repository: https://github.com/ne-foss-org/ne_system

#include <libX11.fwrk/headers/Config.h>

namespace X11 {

namespace Detail {

  static X11ConnectionPtr X11MakeConnection() {
    auto ptr = new X11Connection{};
    if (!ptr) return nullptr;

    return ptr;
  }

  static Void X11DeleteConnection(X11ConnectionPtr ptr) {
    if (!ptr) return;

    delete ptr;
    ptr = nullptr;
  }

}  // namespace Detail

}  // namespace X11