Skip to content

Commit

Permalink
conflicts fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
neoneela committed Nov 29, 2023
2 parents 3f6f08f + d603455 commit e6c1bcd
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
#include <QFrame>
#include <QGridLayout>
#include <QTableView>
#include <QPushButton>
#include <QTabWidget>

namespace hal
{
Expand Down Expand Up @@ -61,11 +63,19 @@ namespace hal


private:
QWidget* createGeneralWidget();
QWidget* createPinWidget();
QWidget* createFlipFlopWidget();
QWidget* createBooleanFunctionWidget();
QTabWidget* mTabWidget;
QGridLayout* mLayout;

QPushButton* mEditBtn;
QPushButton* mAddBtn;
QTableView* mTableView;
GatelibraryTableModel* mTableModel;

GateLibrary* mGateLibrary;
const GateLibrary* mGateLibrary;

bool mReadOnly = false;
};
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,12 @@
#pragma once

#include "hal_core/defines.h"
#include "hal_core/netlist/gate_library/gate_library.h"

#include <QAbstractTableModel>
#include <QList>

#include <filesystem>


namespace hal
{

Expand Down Expand Up @@ -108,7 +107,7 @@ class GatelibraryTableModel : public QAbstractTableModel
*
* @param path - The file path
*/
void loadFile(const QString& path);
void loadFile(const GateLibrary* g);


private:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ namespace hal

if (!fileName.isNull())
{
mTableModel->loadFile(fileName);
//mTableModel->loadFile(fileName);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,17 +85,11 @@ namespace hal
}


void GatelibraryTableModel::loadFile(const QString& path)
void GatelibraryTableModel::loadFile(const GateLibrary* g)
{
if (gPluginRelay->mGuiPluginTable)
gPluginRelay->mGuiPluginTable->loadFeature(FacExtensionInterface::FacGatelibParser);

std::filesystem::path stdPath = path.toStdString();
GateLibrary* g = gate_library_manager::load(stdPath, false);

if (!g)
return;
qInfo() << "adding gate:";
beginResetModel();

for (auto elem : g->get_gate_types())
Expand Down

0 comments on commit e6c1bcd

Please sign in to comment.