Skip to content

Commit

Permalink
Changes
Browse files Browse the repository at this point in the history
  • Loading branch information
manugupt1 committed Sep 14, 2011
1 parent 560ad34 commit a83c60c
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 5 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ project(SaX3)

find_package(Libyui)
set(CMAKE_CXX_FLAGS "-Wall -pedantic -laugeas")
#install(FILES COPYING.GPL-3.0 DESTINATION /usr/share/ax3/)
add_subdirectory(src)
16 changes: 16 additions & 0 deletions COPYING.GPL-3.0
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
SaX3 - openSUSE Advanced X Configuration Utility
Copyright (C) 2011 Manu Gupta<manugupt1@opensuse.org>

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

5 changes: 4 additions & 1 deletion src/lens/xorg.aug
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,9 @@ let match_is_pointer = entry_str "MatchIsPointer" /[mM]atchIsPointer/
(* View: MatchIsTouchpad *)
let match_is_touchpad = entry_str "MatchIsTouchpad" /[mM]atchIsTouchpad/

(* View: Monitor *)
let monitor = entry_str "Monitor" /[mM]onitor/

(************************************************************************
* Group: DISPLAY SUBSECTION
*************************************************************************)
Expand Down Expand Up @@ -274,7 +277,7 @@ let section_entry = option |
identifier |
videoram |
default_depth |
device | match_product | match_vendor | match_is_pointer | match_is_touchpad |
device | match_product | match_vendor | match_is_pointer | match_is_touchpad | monitor |
entry_generic |
empty | comment

Expand Down
2 changes: 1 addition & 1 deletion src/main.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ class Init{
string temp = button[i]->value();
temp.erase(temp.find('&'),temp.find('&'));
cout<<execs[i]<<endl;
err = execlp(execs[i].c_str(),"");
err = execlp(execs[i].c_str(),NULL);//NULL,NULL);
break;
}
}
Expand Down
6 changes: 3 additions & 3 deletions src/monitors.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ void Monitors::separateResolution(string &temp){

void Monitors::detectResolution(){
string temp;int flag=0;
ifstream file("/tmp/sax3-xrandr.tmp");
ifstream file("/tmp/sax-xrandr.tmp");
cout<<"IN DETECT RESOLUTION---->";
if(file.is_open()){
cout<<"File opened";
Expand Down Expand Up @@ -135,13 +135,13 @@ Monitors::Monitors(){

void Monitors::detectDrivers(){
system("rm /tmp/sax*");
system(" xinit `which xrandr` -- :9 -logfile `mktemp --tmpdir sax3.XXXXX` > /tmp/sax3-xrandr.tmp");
system(" xinit `which xrandr` -- :9 -logfile `mktemp --tmpdir sax3.XXXXX` > /tmp/sax-xrandr.tmp");
string temp;
struct dirent * ep;
DIR * dp;
dp = opendir("/tmp/");
if(dp!=NULL){
cerr<<"Directory Opened"<<endl;
// cerr<<"Directory Opened"<<endl;
while(ep=readdir(dp)){
temp = ep->d_name;
if(temp.find("sax3")!=-1 && temp.find(".old")==-1)
Expand Down

0 comments on commit a83c60c

Please sign in to comment.