assignable: install nvidia module

This commit is contained in:
jussi 2019-10-03 16:47:03 +03:00
parent f74f9b71a1
commit 39b5f30c73
5 changed files with 9 additions and 4 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
build build
/*kdev* /*kdev*
**/*swp*

View File

@ -83,7 +83,6 @@ tc_module_t *tc_module_find(enum tc_module_category category, const char *name)
// Call the function to get the module handle // Call the function to get the module handle
tc_module_t *(*mod_info_func)() = tc_dlsym(handle, TC_MODULE_INFO_FUNCTION_NAME); tc_module_t *(*mod_info_func)() = tc_dlsym(handle, TC_MODULE_INFO_FUNCTION_NAME);
//return mod_info_func();
tc_module_t *mod; tc_module_t *mod;
if ((mod = mod_info_func()) == NULL) { if ((mod = mod_info_func()) == NULL) {
tc_dlclose(handle); tc_dlclose(handle);

View File

@ -17,5 +17,7 @@ if all_nvidia_linux_libs
shared_library('nvidia', 'nvidia_linux.c', shared_library('nvidia', 'nvidia_linux.c',
include_directories : incdir, include_directories : incdir,
dependencies : nvidia_linux_libs, dependencies : nvidia_linux_libs,
link_with : libtuxclocker) link_with : libtuxclocker,
install_dir : get_option('libdir') / 'tuxclocker' / 'modules' / 'assignable',
install : true)
endif endif

View File

@ -32,7 +32,7 @@ tc_module_t mod_info = {
.description = "Nvidia assignables", .description = "Nvidia assignables",
.init_callback = &init, .init_callback = &init,
.close_callback = &close, .close_callback = &close,
.category_data_callback = (void *(*)())&category_callback .category_data_callback = (void *(*)()) &category_callback
}; };
tc_module_t *TC_MODULE_INFO_FUNCTION() { tc_module_t *TC_MODULE_INFO_FUNCTION() {

View File

@ -11,7 +11,7 @@ AssignableWidget::AssignableWidget(QWidget *parent) : QWidget(parent) {
m_mainLayout->addWidget(m_splitter); m_mainLayout->addWidget(m_splitter);
m_assignableTreeView = new QTreeView; m_assignableTreeView = new QTreeView;
//genAssignableTree(m_assignableTreeView); genAssignableTree(m_assignableTreeView);
m_splitter->addWidget(m_assignableTreeView); m_splitter->addWidget(m_assignableTreeView);
m_assignableEditor = new AssignableEditor; m_assignableEditor = new AssignableEditor;
@ -32,6 +32,9 @@ void AssignableWidget::genAssignableTree(QTreeView* treeView) {
} }
printf("opened nv mod\n"); printf("opened nv mod\n");
} }
else {
return;
}
QTreeWidgetItem *item = new QTreeWidgetItem; QTreeWidgetItem *item = new QTreeWidgetItem;
tc_assignable_node_t *parent = (tc_assignable_node_t*) nv_mod->category_data_callback(); tc_assignable_node_t *parent = (tc_assignable_node_t*) nv_mod->category_data_callback();